algenty / grafana-flowcharting

Flowcharting, plugin for Grafana to create complexe visio's draws style like technical architectures, floorplan, diagrams, hierarchical schema based on draw.io
Apache License 2.0
966 stars 146 forks source link

Is there a limit of 6 metrics? #163

Closed keifnz closed 4 years ago

keifnz commented 4 years ago

Hi,

Firstly can I say this Grafana Plugin is very impressive. I've just started playing around with it against one of my personal IoT projects running at home.

I've hit upon a weird issue which I'm convinced is user error, but I can't seem to figure out where I'm going wrong.

I've tried creating a number of different diagrams, some using the "Edit Draw" button from a clean "FlowCharting" visualisation. Others by creating a simple image in Draw.Io and then pasting the XML.

However in all my scenarios, no matter what queries I write against InfluxDb - I seem to only be able to access the first 6 metrics.

Here is an example of of the metric list having just clicked in

image

Based on my 2 queries in the bottom diagram, I should have 4 metrics with a "-TempC" suffix, which I can see. I should also have 4 metrics with a "-Humidity" suffix, but only 2 show up. You can see when I start to search of "Office-Humidity" which is definitely there as I have graphs running identical queries, nothing shows up as a match.

image

As further debugging, if I use one of the metrics that shows in the dropdown, you can see the rule summary has a correct Raw Value and suitable Formatted Value

image

If I then type in "Office-Humidity" in this case, you see the Raw Value is null

image

If I then delete my first temperature based query, removing all the data with the "-TempC" suffix, and leaving the single humidity based query with should produce 4 results with a "-Humidity" suffix the rule starts showing the Raw Value and Formatted Value

image

Just to help provide context, here are the two influx queries.

image

I'm sure this is something I'm doing wrong, but I can't for the life of me figure out where I'm going wrong :)

Many thanks in advance, Keith

P.S. Grafana version is 6.7.3 and FlowChartting plugin version 0.8.1

algenty commented 4 years ago

Use the query inspector to verify the number of query in result image

keifnz commented 4 years ago

Hi Arnaud,

Thanks for your super fast reply.

Looks like InfuxDb doesn't use the data element in the object model:

image

But I have made a bit of a discovery which has unblocked me.

If I have this query: image

Then I get a full list of metrics: image

However if I am getting the data from the same source but using two more discrete queries:

image

Then I get the issue where I can't refer to all the metrics that result from these two queries (there should be 8 items in the list): image

I've started to detect that there may be a pattern which seems to depend on the source of the first query. This is based on some things I spotted using multiple data sources. Though it's only a hunch at the moment and I can't quite think how to articulate it.

I've found a way forward now thanks :) If I think I can shed more light on this I'll update the issue.

Many thanks, Keith