3

A follow-up question from Graphite: sum all stats that match a pattern?:

Is there any Graphite magic to recursively descend node names? I now know that I can use patterns like so:

stats.timers.api.*.200.count

... but imagine that I have the following:

stats.timers.api.foo.bar.200.count
stats.timers.api.baz.200.count

I'd like to see both of those stats (and all others of arbitrary depth) on the same chart. I tried the following:

stats.timers.api.*.200.count
stats.timers.api.**.200.count

The former only shows me items like the 'baz' example above; the latter is an error.

Is there some other way to match metrics in a depth-insensitive manner?

Community
  • 1
  • 1
Patrick Linskey
  • 1,124
  • 1
  • 13
  • 24

2 Answers2

3

A neater, single line version of dannyla's answer would be:

stats.timers.api.{*,*.*,*.*.*}.200.count

But the short answer to your question would no, there's no magic to recursively descend node names.

Dave Wongillies
  • 293
  • 2
  • 5
1

I know its not the 100% what you are after, however you can have multiple targets on the same graph.

You could just combine the below on to the same graph that will give you the results, however not the clean solution your after.

stats.timers.api.*.200.count
stats.timers.api.*.*.200.count
stats.timers.api.*.*.*.200.count
dannyla
  • 1,960
  • 14
  • 13