Giter Club home page Giter Club logo

grafana-discrete-panel's People

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

grafana-discrete-panel's Issues

snapshot does not work

I just generating a snapshot on grafana 4, but it just showed an empty panel.

Has this feature been added?

also , does it work on grafana 5?

support aligning panel to standard graphs

I am using a discrete panel to separate my graph into shifts but due to the axis on the graph panel my x axes do not quite line up.
It would be good to implement a custom offset to the left and right of the discrete panel to let the user align panels for different widths of axis labelling.
image

JS error : Cannot read property 'changes' of undefined

Hi,

With v0.0.5, I have the following error in the console:

module.js:596 Uncaught TypeError: Cannot read property 'changes' of undefined
    at DiscretePanelCtrl.onGraphHover (module.js:596)
    at f.eval (canvas-metric.js:270)
    at f.emit (boot.d709d8d5.js:61)
    at a.emit (boot.d709d8d5.js:61)
    at HTMLCanvasElement.eval (canvas-metric.js:172)

In that dashboard, I have a few discrete panels that are empty : no data in the selected time window.
If I collapse the rows with the empty panel, the tooltips can appear on some rows, but it's not predictable...

With v0.0.4, it did not work either.

Let me know if you need more info !

Time shown on X-axis

Thank you very much for this panel, it is very useful.

I would like to request you if it is possible to show the time directly on the X-axis as for the typical Grafana graphs.

And again, great job!

[Feature proposal] Gunt chart - legend of a distinct values

Hi,

Currently after enabling a legend we are getting a list of keys that occur in a selected time perspective for every metric. This makes legend quite unreadable:

grafanagunt

Would it be possible to include an option for a legend to display only a distinct list of values ? The goal is to have a smaller but usable legend.

Kind Regards

Value mappings not working

Firstly, thanks a ton! This is a great Grafana panel. Very handy indeed.

I've found that the value mappings don't seem to work. I've got the following ones configured:

screen shot 2017-04-02 at 15 24 00

[Enhancement Request] Option to display count of transitions.

Thanks for this panel, it's something Grafana has been sorely lacking for a very long time! :)

As title says, I would like to be able to display a count of transitions.

Even better would be some kind of histogram of transition count (e.g. number of transitions per hour, with hourly buckets).

Incorrect state being indicated

I have a line graph showing the voltage of a particular lithium battery consisting of 16 separate cells (3 V each, in series, to form a 48 V battery). The image below shows the information correctly depicted. A line graph above showing the cell voltage minima and maxima, the difference between the two and a discrete panel (v0.5) showing the cell balancing activity (depicted by either a 0 or 1 in the InfluxDB database).

screen shot 2017-07-31 at 23 34 19

Sometimes, however the discrete panel doesn't function correctly. As you can see in the image below there is no data for the time period shown (i.e. the blank line graph), however the discrete panel tells me balancing is occurring 100% of the time.

screen shot 2017-07-31 at 19 13 01

This issue also comes up in other circumstances. Take a look at the image below and notice the balancing state at this particular cursor position (i.e. no balancing):

screen shot 2017-07-31 at 23 45 09

Now if I take the exact same graphs and just zoom in a little bit, notice what the balancing state is at the exact same timestamp as the image above (i.e. balancing):

screen shot 2017-07-31 at 23 46 05

I'm really not sure what is going on here but it is fairly critical to the usefulness of this panel. Just for reference purposes, here is the InfluxDB query I'm using:

SELECT distinct("balancing_state") FROM "bms_balancer_status" WHERE "bms_balancer_id" =~ /^$bms_balancer_1$/ AND $timeFilter GROUP BY time($interval) fill(none)

Just let me know if I can be of any further help to sort this issue out.

Request error on format as table

Hi to all.
First if all thanks for your work. Panel is good.
I have string data in my DB and can`t display them in panel. When i use 'format as table', panel showed "Request Error" (but don't write any errors) if i change format to time all is good.
But, if it's timeserias format all data is null, not string...
My SQL:

SELECT
  UNIX_TIMESTAMP(OpenHAB.Item8.Time) as time_sec,
  OpenHAB.Item8.Value as value
FROM OpenHAB.Item8
WHERE $__timeFilter(OpenHAB.Item8.Time)

image

Cannot read property 'to' of undefined Grafana 4.5.0

Hi

I get the following error on immediately after adding the panel

TypeError: Cannot read property 'to' of undefined
    at DiscretePanelCtrl.issueQueries (https://grafana.lightricks.com/public/plugins/natel-discrete-panel/module.js?bust=1505394229707:425:34)
    at i (https://grafana.lightricks.com/public/app/boot.4aeac494.js:61:3972)
    at https://grafana.lightricks.com/public/app/boot.4aeac494.js:61:4394
    at o.$eval (https://grafana.lightricks.com/public/app/boot.4aeac494.js:61:11549)
    at o.$digest (https://grafana.lightricks.com/public/app/boot.4aeac494.js:61:10022)
    at o.$apply (https://grafana.lightricks.com/public/app/boot.4aeac494.js:61:11832)
    at https://grafana.lightricks.com/public/app/boot.4aeac494.js:61:7882
    at f (https://grafana.lightricks.com/public/app/boot.4aeac494.js:59:22132)
    at https://grafana.lightricks.com/public/app/boot.4aeac494.js:59:23593

show in legend text from value mappings

How show in legend text from value mappings?
I set up a value mapping, but not the text but the value is displayed in the legend. How to fix?
1
2
Only one value displays text-this is null
Thanks

Annotations

Hello, great job with the panel and thank you a lot. Would it be possible to be able to add annotations to the panel?

Override Relative Time XXd not working

thanks for the great panel...

not that important to me, but the panel doesnt seem to look at any define 'Override Relative time'
it just uses the dashboard time spans

Count & Group String by values not by timestamp

I'm trying to group my metrics in three states RED, YELLOW & GREEN, them, are stored in InfluxDB as a string, the query is : SELECT "YYYY" FROM "XXXX" WHERE $timeFilter but the results are always the same, sorted by tiemestamp and not grouped by value like in the screenshots provided in the readme.

Desired representation:
image

Actual representation:
image

(Legend works correctly)

Is there any kind of bug or am I doing something wrong?

By the way, great job with the panel!

Bug after Version 4.6.3 December 14, 2017

Horizontal scrollbar?

Why is there a navbar on the bottom of all of our discrete panels? I keep our Grafana very updated, so perhaps a recent update broke this (or added it)? It looks terrible.
navbar

Prometheus issue with "step" value in query

Hi,

I am currently facing some issues with my prometheus query inside the discrete panel. I have added my queries to the discrete panel and set the time range to "previous month".
With this big time range I am trying to calculate the server uptime in % and how long a server wasn't available. Because of this i have to set the "min step" option in Grafana to "60s". But somehow grafana won't add this value to the prometheus query. Inside the query the "step=" Option stays the same no matter what option I am choosing for "min step".

Furthermore I noticed that this "step=" option is diffrent from the Browser I am using.
I have tested it with Firefox and Chrome. In Firefox the step value inside the query is "900" and for Chrome it is "1200".

I don't know if this is actually a problem from the plugin or Grafana itself. Currently i couldn't verify this behaviour with the bultin Graph Panel from Grafana.

Expand 'from' query option not working correctly

I just upgraded discrete panel to 0.0.7 from 0.0.6 and Grafana from 4.6.3 to 5.0.4 and the "Expand 'from' query" option is no longer working as it used to. When I enter some number of seconds, Grafana expands both the the query and the displayed graph by that amount instead of just the query. So if my time range in Grafana is set to 'now-24h' and I enter Expand 'from' query: 86400, then the displayed graph is 2 days long instead of 1 day.

hover makes metric name disappear

Hi, when I hover over a row to see some details, the metric name at the left side of the row disappears while hovering. Is there any way to prevent that from happening? I have enough rows that it's confusing if those labels go away.

Thanks!

Rendering v2

This is how my rendering looks like:

  onRender() {
    if(this.data == null || !(this.context)) {
      return;
    }
    this._updateRenderDimensions();
    this._updateSelectionMatrix();
    this._updateCanvasSize();
    this._renderRects();
    this._renderLabels();
    this._renderSelection();
    this._renderCrosshair();
  }

I render everything by layers, keeping selectionMatrix - matrix bitmap of selected rects and additional info: https://github.com/CorpGlory/grafana-discrete-panel/blob/master/src/module.js#L175

It is remade rendering which allows me to make many new features on top of it and makes code mush cleaner.

This rendering also makes appearance different: different labels positions, styles of rects, selection, and crosshair.

[Enhancement] Prevent metric name and first value overlap

With the "Write Metric Names" option selected one ends up with the first value in the discrete series overlapping the metric name, as shown in the image below

screen shot 2017-04-20 at 11 24 26

However when one hovers the mouse over the metric name it then disappears, clearly showing what the first value is (see image below):

screen shot 2017-04-20 at 11 25 05

It would be super if, when the first value is to be shown, it would always cause the metric name to fade away, thereby making it clearly visible.

Grafana 5.1 breaks legend

I believe the 5.1 update breaks the legend for the Discrete Panel. Here is a screenshot of what is happening:

screen shot 2018-05-02 at 4 50 02 pm

Scrollbar missing on embedded panel with Grafana v5

Hey. Not sure if this will be fixed with the recent commits but after the upgrade to Grafana v5.0.0 the panel lost it's scrollbar when it's embedded in an iframe.

This means if the panel is bigger than the iframe area it just gets cut off.

Legend information interpolated in the rows

Hi,

First of all, nice plugin. Now, the use case I have.

I need to show a lot of different rows in the panel, but having the legend only at the end makes it very hard to get useful information out of it.

I have been playing a little bit with the code to get something I could use and I was wondering if you think it might be useful in general, and in case it is, do you accept contributions to the plugin?

In this case I added a new option to show the legend interpolated, which created an extra row per data point and adds the metric name (alias) + the legend information for the specific point.
As you can see in the image is not overwriting the legend functionality at all, rather adding some extra one.

image

Thanks.

Support Grafana 3.x

this panel uses some lodash functions that are only supported in 4.x. These functions may be easy to replace with versions that don't require the recent lodash.

See #17

If anyone has the time and attention to port this to functions that are supported in 3.x, that would be great

Indicating state into the future

I'm not sure whether this is a bug or whether I've incorrectly constructed my query. The custom zoom shown in the image below spans a few days into the past and a few into the future. The discrete panel doesn't stop showing state at the point where data is no longer available

screen shot 2017-04-02 at 15 38 30

Just to put this into context, below is a screenshot showing this compared to some of our other data.

screen shot 2017-04-02 at 15 42 19

render text top/bottom/middle

Before the new pipeline, everything was middle aligned. The new pipeline made some stuff top and other things bottom. This is better sometimes, but by default everything in the middle is nice.

image

I put back middle align, and we can look at other options in follow on issue

@jonyrock

[enhancement request] increase significant digits for percentage?

First, awesome panel! I approximated something like this before with the built in panels, but your panel is way easier.

Enhancement request: I plot 7 days worth of 1s and 0s of service availability. It would be great if I could have percentages shown with more significant digits. ie, to try and show five 9s of availability. It looks like it's rounded up currently to 99% or 100%. Nothing in between.

Thanks!

Direct link rendered image failed

I'm trying to render the discrete panel as an image via the "Direct link rendered image" Button inside the share panel option.

The Website which will open then just loads and after about 1 minute I'm getting an error page.

Inside the Grafana Logs I found this:

lvl=info msg=Rendering logger=png-renderer path="d-solo/XGWXldimz/reporting?orgId=1&panelId=6&from=1519858800000&to=1522533599999&width=1000&height=500&tz=UTC%2B02%3A00"
lvl=eror msg="Request Completed" logger=context userId=0 orgId=1 uname= method=GET path=/render/d-solo/XGWXldimz/reporting status=500 remote_addr=192.168.1.141 time_ms=60003 size=1763 referer="http://grafana:3000/d/XGWXldimz/reporting?orgId=1"
lvl=eror msg="failed to render an image" logger=png-renderer error="signal: killed"

I have also tried to set the log level from grafana to debug, but nothing more is displayed here.

On the error site I am getting I see the following message: Timeout error. You can set timeout in seconds with &timeout url parameter". Unfortunately setting the timeout parameter to a very high number doesnt help aswell here.

What data sources does this panel support?

It's not really clear which different Grafana datasources that this plugin will work with. Any datasource that would return a value shows the error _.isNil is not a function.

I'm assuming I can use value and range mappings to convert values to text, or be able to use a metrics that only contains 0 or 1 values such as an AWS CloudWastch HealthStatus cluster metric, but they all end up showing this error: https://dl.dropboxusercontent.com/s/kx4bik0mmc6ir5g/2017-06-13%20at%201.05%20PM.png

What data sources does this panel actually support?

Thanks

Sorry to open an issue but the discrete is a revelation of occupancy monitoring. In one use case Desks in offices. And soon to replace Motioning of Elderly.

A big thanks & keep up the great work.

[Feature Request] Make font size settable

It would be great if you could set the font size of the values shown in each line. For example if I reduce the row height to show a lot of discrete rows, I'd also like to reduce the font size to match the discrete row height.

screen shot 2017-04-02 at 15 29 11

[Enhancement] Automatic color scheme

Hi,
if used with many different values, assigning colors is much work. Therefore, could you please add an option to set colors automatically? Each color could be assigned somewhat like this:

color = hash(value name) [use first 6 byte as rgb value]

Thank you!

0.0.7 value mappings broken. 0.0.6 works fine

Just upgraded to 0.0.7 and the value mappings no longer apply. 0.0.6 works fine. No changes to config; I can replicate just by switching between versions.

Grafana v4.4.1, running in official grafana/grafana docker image.

Documentation to use this pane

Hi,

This looks like a great plugin, but I'm having an issue where I need to plot string values. If I choose a field where they are numeric, I get that data plotted. However, selecting a field that contains two string - I get nothing displayed.

Thanks.

support "To the right" for Legends

It would be great if one could move the legend to the right of the panel like in other panels.

image

image

This would save much space on width monitors.
image

[Feature Request] support local snapshots

I've tried to share a local snapshot of a dashboard with the discrete panel used. When checking the snapshot however it seems all data for the discrete panel is lost, and nothing is shown.

Tooltip information incorrect

I have two metrics in a single discrete panel. When mousing over I see the following:

screen shot 2017-04-02 at 17 21 03

  • The tooltip text only refers to the bottom metric, even though my mouse is over the top metric.
  • The indicated time is rounded off to full days whereas I'd expect to see something like 3 days, 4 hours, 21 minutes, 47 seconds or for brevity 3d, 4h, 21m, 47s

Legend and percentages

Hi,
Nice panel; sadly, I experienced some problems with the legend.

Sometimes not all occuring values are represented in the legend area:
screenshot1

Also, percentage sometimes exceeds 100%:
screenshot2

Thanks for your work!

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.