I am trying to use multiple template variables in a single metric query path. The datasource is Graphite.
My whisper file looks like: indices_artifact-11_english_total_merges_total-size.wsp and I have split out the index name and metric name into template variables with regexes. The index name and index metric name populate into the template variable dropdown fine, but attempting to access them in a single query path (or box) yields nothing (no error). I did have it working yesterday but my query got blown away so it should work (because I know it has). I also understand that I may be on the edge of supported functionality. If anyone has done something similar, I would appreciate some advice.
Currently, the query looks like this, where the $index would be artifact-11_english and $indexname would be total_merges_total-size
@torkel that does not seem to help either. My regex must not be fully correct (maybe a whitespace issue?). Unfortunately the plugin I am using does not split index metrics into appropriate pathing (i.e. ...indices.$index.$indexmetric).
I’m running into this issue as well … no combination of [[varname]] or $varname works with underscores.
Trying to do something like this
icinga2.$component-$deployment$-$number_$environment$_$ec2region.services.check_cpu.check_cpu.perfdata.USER.value
Everything works up to and after the underscores. I’ve tried [[varname]] as well and it doesn’t work. Query inspection looks something like this:
data:“target=icinga2.%7Bwebapi%7D-beta%24-%24number_%7Bprod%7D%24_%24ec2region.services.check_cpu.check_cpu.perfdata.USER.value&from=-6h&until=now&format=json&maxDataPoints=1908”
I’m also seeing the same issue using Hosted Graphite. It stops seeing metrics beyond hyphens for me. I’ve tried $varname and [[varname]] with hyphens in between, asterisks in between, and mixtures of them all and I can’t seem to get it to work.
This has been resolved from changing the regex to a different format to collect the same information. It then started rendering the query successfully. When I revert the regex back to the old format, it is still working!