-
Notifications
You must be signed in to change notification settings - Fork 2
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Tagged demo #7
base: master
Are you sure you want to change the base?
Tagged demo #7
Conversation
How tags are exposed / used in grafana? |
Who manages |
It is managed by clickhouse-carbon, see this. It is parsed here: all keys in the string are sorted and repeated keys are deleted. You can see in the tests examples of resulting string. It will be then added to |
so basically old tags are never deleted? |
If I'm not mistaken, yes. It can be a problem since metrics can have a huge amount of different tags? Maybe we can drop too old partitions periodically through some demon (delete is now supported in CH) |
Things like tags exploding happen: when something is marked as tag by error. Just imagine more or less random data (strings and numbers) going directly to 2003 port. Suddenly you can end up with 100500+ different things labeled as tags with no semantics. |
What do you mean? Grafana has no knowledge about tags in CH, I just write some query that that us using some tags for filtering. |
Usually people use grafana template variables for this. With template variable of type "Query" you can get a list of possible tag values. Then you can use this variable in query. For example you can have template variable for hostname: with drop-down menu (or using GET parameters) user specifies one or more hostnames and grafana shows only data for selected hostnames. i.e. tag values query |
If these template variables rely on query, would they be automatically updated if I will insert some data that changes the result of this query (for example new tags), or I should update these templates manually after it? |
Grafana can update them, yes |
is it WIP? |
No, I added template variables. |
Could you please rebase? |
eb8394d
to
099019e
Compare
rebased |
This demonstrates how tagged series can be inserted in CH with carbon-clickhouse.
Also with tags I need to create more complex queries for Grafana, like
for selecting all series with both tag
a=1
andb=5
. This query selects tagged metric paths from special table (graphite_tagged
) and joins it with the main (graphite
) table.Pros:
Cons:
graphite_tagged
table