Commit Graph

65 Commits

Author SHA1 Message Date
Julius Volz 0229a89925 Fix graph JS glitches and simplify graphing code.
- original series data is saved so it can be re-transformed after
  Rickshaw's stacking modified the series data

- always reconstruct graphs from scratch instead of updating the
  settings of an existing one (simplification)

- always wipe and recreate all graph-related DOM elements completely so
  that no left-over event handlers cause background event handlers
2015-02-06 23:51:37 +01:00
Julius Volz 0e8c0b67ad Remove custom hover flip code. Fixed upstream. 2015-02-06 15:02:13 +01:00
Julius Volz 517a731ebf Show unlimited number of metrics in autocomplete. 2015-02-06 02:03:08 +01:00
Julius Volz d4374a9265 More efficient JSON query result format.
This depends on https://github.com/prometheus/client_golang/pull/51.

For vectors, the result format looks like this:

```json
{
   "version": 1,
   "type" : "vector",
   "value" : [
      {
         "timestamp" : 1421765411.045,
         "value" : "65.475000",
         "metric" : {
            "quantile" : "0.5",
            "instance" : "http://localhost:9090/metrics",
            "job" : "prometheus",
            "__name__" : "http_request_duration_microseconds",
            "handler" : "/static/",
            "method" : "get",
            "code" : "304"
         }
      },
      {
         "timestamp" : 1421765411.045,
         "value" : "5826.339000",
         "metric" : {
            "quantile" : "0.9",
            "instance" : "http://localhost:9090/metrics",
            "job" : "prometheus",
            "__name__" : "http_request_duration_microseconds",
            "handler" : "prometheus",
            "method" : "get",
            "code" : "200"
         }
      },
      /* ... */
   ]
}
```

For matrices, it looks like this:

```json
{
   "version": 1,
   "type" : "matrix",
   "value" : [
      {
         "metric" : {
            "quantile" : "0.99",
            "instance" : "http://localhost:9090/metrics",
            "job" : "prometheus",
            "__name__" : "http_request_duration_microseconds",
            "handler" : "/static/",
            "method" : "get",
            "code" : "200"
         },
         "values" : [
            [
               1421765547.659,
               "29162.953000"
            ],
            [
               1421765548.659,
               "29162.953000"
            ],
            [
               1421765549.659,
               "29162.953000"
            ],
            /* ... */
         ]
      }
   ]
}
```
2015-01-26 13:06:22 +01:00
Brian Brazil 2b07cd3875 Keep total counter outside out loop.
This was causing only the last expression to be graphed.
2015-01-26 10:51:38 +00:00
Stuart Nelson 8ada6360ef Add floats to align inputs, and clear the float on the parent. 2015-01-22 13:27:35 +01:00
Julius Volz 4133020de1 Align graph controls with graph edge. 2015-01-20 16:43:23 +01:00
Julius Volz 12a99ab5b4 Some more UI/JS fixes/cleanups. 2015-01-19 14:27:07 +01:00
Julius Volz 170da9460d Focus/typeahead fix. 2015-01-19 13:33:56 +01:00
Julius Volz d96d4933d9 Complete Bootstrap 3 conversion.
- use the autocomplete plugin from
  https://github.com/bassjobsen/Bootstrap-3-Typeahead
- use native Bootstrap tabs
- make everything look much nicer (hopefully)
- other minor fixes/additions
2015-01-19 01:29:30 +01:00
Julius Volz ff5eeb49fa Fix datepicker timezone issues. 2015-01-14 15:09:58 +01:00
Stuart Nelson 0529e3fcfa Use datetimepicker. 2015-01-12 14:18:28 +01:00
Stuart Nelson 3814daac48 Make Loadtime/ Resolution info look nicer. 2015-01-09 14:23:09 +01:00
Stuart Nelson 071d98f3d0 Square corners 2015-01-09 14:23:00 +01:00
Stuart Nelson 7b9bf8d3e5 Query header. 2015-01-09 14:12:52 +01:00
Stuart Nelson 46f7bd2820 graph controls 2015-01-09 13:55:01 +01:00
Julius Volz 8ce89f0086 WIP: Upgrade to Bootstrap 3. 2015-01-09 10:15:56 +01:00
Brian Brazil ffa2e73803 Fix regression from 5e8d57bec1
0 is a false value, so shortcutting no longer works.
Update other places in the code that assumed graph was the default.
2014-12-27 00:28:36 +00:00
Brian Brazil 43b105d32d Console templating library, including graphs.
This provides the basic js, css and console template
templates required to build dashboards.
Included as an example are consoles for the node_exporter.

Change-Id: I4cfeea5e9691a9413f74ae98ca32a908df8e4a59
2014-12-18 16:54:31 +00:00
Julius Volz af8c6df94d Eliminate modal alerts in graphing UI.
This shows errors in a pane under the expression input instead.

Change-Id: Iec209e1628a3b102cce9f34b2467621772dfb8ff
2014-11-25 17:13:04 +01:00
Julius Volz 5e8d57bec1 Make tabular view the default (vs. graphing view).
Change-Id: I9f0961f2c474e8cce5e376ce4e20040644f89370
2014-11-25 17:13:04 +01:00
Julius Volz 3d47f94149 Drop metric names after transformations.
After many transformations, it doesn't make sense to keep the metric
names, since the result of the transformation is no longer that metric.
This drops the metric name after such transformations and makes the web
UI deal well with missing metric names.

This depends on the current branch on the following things:

- prometheus/client_golang needs to be at
  e237cf15c6
  in branch "julius/int-fingerprints" (to be merged with new storage)

- prometheus/promdash needs to be at
  dd7691c9c2

Change-Id: Ib3c8cad8d647d9854e8c653c424b8c235ccc231d
2014-11-25 17:13:04 +01:00
Brian Brazil 75e37db55b Don't alert() when a query is aborted,
such as when you change the range.

Change-Id: I574504f97446ac5f3dda737fe054ae83f17dbbc2
2014-11-25 17:09:04 +01:00
Andres Suarez e389e63684 Focus expression after selection from dropdown
Change-Id: Id7f67e558e3611ab4c7188cc428c342d8d3e67db
2014-11-25 17:08:26 +01:00
Andres Suarez 86a447fc0e Allow selecting metric from Insert Metric
Change-Id: I99e0539cab2749a8aeabc0a13015889ff45834f7
2014-11-25 17:08:26 +01:00
Brian Brazil f525ca5d9e Let consoles get graph links from experssions.
Rename ConsoleLinkFromExpression, as we now have consoles.

Change-Id: I7ed2c9c83863adb390b51121dd9736845f7bcdfc
2014-11-25 17:01:59 +01:00
Julius Volz cc04238a85 Switch to new "__name__" metric name label.
This also fixes the compaction test, which before worked only because
the input sample sorting was accidentally equal to the resulting on-disk
sample sorting.

Change-Id: I2a21c4b46ba562424b27058fc02eba84fa6a6006
2014-03-14 16:52:37 +01:00
Julius Volz fcf784c13c Fix query error notification in tabular view.
Instead of "Unsupported value type" when type="error", the delivered
error message should be shown.
2013-08-02 09:04:13 +02:00
Julius Volz 481ee4096b Add no-op silencing links. 2013-07-24 15:09:42 +02:00
Julius Volz d9f403ab7d Prettify/Bootstrapify alert tables. 2013-07-24 15:03:13 +02:00
Julius Volz f665534b61 Make quote and semicolon usage consistent in graph.js 2013-07-24 12:29:03 +02:00
Julius Volz c91c100102 Fix graph resize bug when no graph exists. 2013-07-24 12:29:03 +02:00
Julius Volz 9f07f8677a Generate tabular console view from JSON data. 2013-07-24 12:28:59 +02:00
Sabra Melamed 22ab2366c1 Replacing interface components with Bootstrap.
This commit includes Bootstrap 2.3.2 and swaps a multitude of graph,
status, and other components to Bootstrap-based widgets.
2013-07-23 20:58:55 +02:00
Julius Volz f42adc1cc0 Display Y-axis outside of graph. 2013-07-01 14:47:43 +02:00
Julius Volz 0226d1ac7a Implement alerts dashboard and expression console links. 2013-06-13 22:35:40 +02:00
Julius Volz 8586c7520c Support negative graph values.
Currently graph Y-Axes were hardcoded to start at 0. Choose the Y-scale
automatically based on the graph data instead.
2013-05-21 16:54:33 +02:00
juliusv cfc3b1053d Merge pull request #212 from prometheus/ui/smaller-navigation-links
Restyle navigation a bit, align content elements with it
2013-05-03 07:00:09 -07:00
Julius Volz f3cf8eae7e Restyle navigation a bit, align content elements with it. 2013-05-03 15:49:08 +02:00
Johannes 'fish' Ziemke c5e507cd9c Never submit empty queries. 2013-05-02 16:55:47 +02:00
Johannes 'fish' Ziemke ba289ef7cd Add the console to the main/graph ui. 2013-05-02 12:19:34 +02:00
Johannes 'fish' Ziemke 712bf5e2f9 Add per graph auto-refresh option to web UI.
This adds a drop-down menu to select/disable a auto-refresh interval.
2013-04-22 11:42:23 +02:00
Bernerd Schaefer 72bd585485 Revert style change to legend items 2013-04-15 10:04:09 +02:00
Bernerd Schaefer 442a6d2b11 Use $ instead of jQuery 2013-04-12 13:43:53 +02:00
Bernerd Schaefer 953334a4f7 Reformat and add semicolons to graph.js 2013-04-12 13:41:53 +02:00
Bernerd Schaefer 43dc377bee Flip x_label when it would render off-page 2013-04-12 11:59:49 +02:00
Bernerd Schaefer 461e02d2b8 Flip hover detail to prevent going off the screen 2013-04-12 10:39:37 +02:00
Bernerd Schaefer 8c9597cb39 Render legend in a similar style to labels 2013-04-12 10:39:15 +02:00
Bernerd Schaefer a7ec43189a Hovering over legend items highlights series in graph 2013-04-12 09:34:12 +02:00
Bernerd Schaefer 564633ecbc Render graph labels vertically
This helps to make the timeseries with many labels fit on the screen.
2013-04-12 09:34:12 +02:00