Commit graph

238 commits

Author SHA1 Message Date
Fabian Reinartz 3b0777ff84 Merge branch 'master' into fabxc/servdisc 2015-05-12 15:46:16 +02:00
Fabian Reinartz eeca323d24 Merge branch 'master' into promql 2015-05-06 13:04:54 +02:00
Fabian Reinartz 6649306e63 Merge pull request #660 from prometheus/fabxc/pql/parse-errs
Fix and improve parsing error output.
2015-04-30 13:31:13 +02:00
Fabian Reinartz 279831cdf1 Fix and improve parsing error output. 2015-04-30 12:19:39 +02:00
Fabian Reinartz 8d7c479fed Merge pull request #658 from prometheus/fabxc/pql/rules-manager
Rename RuleManager to Manager, remove interface.
2015-04-29 16:54:21 +02:00
Fabian Reinartz 479891c9be Rename RuleManager to Manager, remove interface.
This commits renames the RuleManager to Manager as the package
name is 'rules' now. The unused layer of abstraction of the
RuleManager interface is removed.
2015-04-29 16:42:10 +02:00
Fabian Reinartz 25cdff3527 Remove name arg from Parse* functions, enhance parsing errors. 2015-04-29 16:38:41 +02:00
Fabian Reinartz 3ca11bcaf5 Switch Prometheus to promql package.
This commit removes all functionality from rules/ that is now handled in
promql/.
All parts of Prometheus are changed to use the promql/ package.
2015-04-28 16:19:23 +02:00
Fabian Reinartz 5015c2a0e8 Make target manager source based.
This commit shifts responsibility for maintaining targets from providers and
pools to the target manager. Target groups have a source name that identifies
them for updates.
2015-04-24 15:49:35 +02:00
Brian Brazil c3a2b63fe9 Add stddev and stdvar aggregation functions.
This adds the population standard deviation and
variance as aggregation functions, useful for
spotting how many standard deviations some samples
are from the mean.
2015-04-17 00:30:03 +01:00
Ceesjan Luiten 6f5f33bd4d #625 Fix incorrect consoles URL 2015-04-06 17:30:13 +02:00
Ceesjan Luiten 0e18784c64 Make all paths absolute to support proxies 2015-04-02 20:36:47 +02:00
Julius Volz 33702da8a8 Use simple Now() func in API instead of utility.Time. 2015-03-27 23:43:47 +01:00
Julius Volz a5a553f1da Add initial HTTP API tests.
This covers the /query (instant query) endpoint for now. Others to
follow.
2015-03-27 21:37:55 +01:00
Julius Volz 3f2686d0b3 Remove unused fields from MetricsService. 2015-03-27 18:51:13 +01:00
Julius Volz c8a6b73bff Merge pull request #606 from prometheus/custom-instant-timestamps
Allow custom timestamps in instant query API.
2015-03-27 18:31:51 +01:00
Julius Volz c9b76def4c Report all query API HTTP errors in JSON format. 2015-03-27 16:48:03 +01:00
Julius Volz ea8a12db59 Also fix label HTML-escaping in console graphs. 2015-03-22 23:47:00 +01:00
Julius Volz 8f6ef04d70 HTML-escape label values in Rickshaw hover-detail. 2015-03-22 21:59:14 +01:00
Julius Volz df314ead84 Remove unnecessary "else" branch in query API. 2015-03-21 17:54:30 +01:00
Julius Volz a68b880c27 Add tests for new timestamp/duration functions.
...and fix the first bugs in them where they truncate precision below a
second.
2015-03-21 17:50:45 +01:00
Julius Volz cb816ea14a Improve timestamp/duration parsing in query API.
Don't handle `0` as a special timestamp value for "now" anymore, except
in the `QueryRange()` case, where existing API consumers still expect
`0` to mean "now".

Also, properly return errors now for malformed timestamp/duration
float values.
2015-03-21 16:58:45 +01:00
Julius Volz 8a4acefd66 Allow custom timestamps in instant query API. 2015-03-20 23:10:58 +01:00
Julius Volz c78436d707 Remove unused API time dependency injection. 2015-03-20 23:10:26 +01:00
Björn Rabenstein 942686427d Merge pull request #596 from prometheus/beorn7/ingestion-tweaks
Remove the ingestion channel.
2015-03-19 17:56:55 +01:00
Julius Volz 6fa510d6fa More fixes around special values in graphs. 2015-03-19 14:26:25 +01:00
beorn7 fa1935a644 Remove /api/targets call and do not show job and instance labels on status.
/api/targets was undocumented and never used and also broken.

Showing instance and job labels on the status page (next to targets)
does not make sense as those labels are set in an obvious way.

Also add a doc comment to TargetStateToClass.
2015-03-18 18:53:43 +01:00
beorn7 be11cb2b07 Remove the sample ingestion channel.
The one central sample ingestion channel has caused a variety of
trouble. This commit removes it. Targets and rule evaluation call an
Append method directly now. To incorporate multiple storage backends
(like OpenTSDB), storage.Tee forks the Append into two different
appenders.

Note that the tsdb queue manager had its own queue anyway. It was a
queue after a queue... Much queue, so overhead...

Targets have their own little buffer (implemented as a channel) to
avoid stalling during an http scrape. But a new scrape will only be
started once the old one is fully ingested.

The contraption of three pipelined ingesters was removed. A Target is
an ingester itself now. Despite more logic in Target, things should be
less confusing now.

Also, remove lint and vet warnings in ast.go.
2015-03-15 14:08:22 +01:00
Julius Volz 91da12ad6a Show special float values as gaps. 2015-03-13 21:08:22 +01:00
Julius Volz 52ce3599c9 Nicer formatting of target health table on /status. 2015-03-07 23:35:28 +01:00
juliusv 5a4fe403ff Merge pull request #514 from prometheus/fix-graph-js-errors
Fix graph JS glitches and simplify graphing code.
2015-02-09 13:17:28 +01:00
Julius Volz 989bc86bcb Make flag names consistent across projects. 2015-02-08 23:29:57 +01:00
Tobias Schmidt 655dffe393 Update help URL 2015-02-07 05:10:12 -05:00
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
juliusv 9e6b3bcefa Merge pull request #498 from fabxc/feature/query_timeout
Implement query timeouts
2015-02-03 13:51:47 +01:00
Fabian Reinartz fa1e90003b Query timeout added.
This is related to #454. Queries now timeout after a duration set by
the -query.timeout flag. The TotalEvalTimer is now started/stopped
inside any of the ast.Eval* functions.
2015-02-03 08:04:27 +01:00
Julius Volz b3978fe869 Fix Rickshaw/D3 version mismatch.
When Rickshaw was updated to 1.5.1 in
fd43daf82e,
the Rickshaw upstream package now contained 3 different D3 files:

d3.min.js
d3.v2.js
d3.v3.js

For details on why that is, see
https://groups.google.com/forum/#!topic/d3-js/lXQgKA7mtEw

For the 1.5.1 Rickshaw to work properly (being able to format dates with
D3 without causing a JS error), it needs d3.v2.js or d3.v3.js, not the
d3.min.js one. I chose to update us to d3.v3.js now, since that is the
most recent and minified version, and I didn't see any problems with it
(also, the current Rickshaw examples are using that D3 version).

Currently, displaying graphs with a range >14d is broken. This fixes
that.
2015-02-02 23:41:36 +01:00
Bjoern Rabenstein f568bbc19f Improve comments about embedding. 2015-02-02 12:37:39 +01:00
Tobias Schmidt edadba3b25 Merge web/blob/Makefile into web/Makefile
While the recent commit 7e5745f solved the issue of having an
independent blob-stamp file, which was possible to become out of
sync with the necessary web/blob/files.go file, this change further
simplifies the setup by merging the two Makefile.
The only purpose of web/Makefile was to call targets in
web/blob/Makefile. As all dependencies for blob/files.go are
outside of the blob/ directory, the separation isn't logically
necessary.
2015-01-29 19:12:32 -05:00
Björn Rabenstein 855f20a4d3 Merge pull request #470 from prometheus/beorn7/slim-static-assets
Slim down the files we embed into the binary.
2015-01-26 15:24:15 +01:00
Bjoern Rabenstein 3fc354c4ce Update help link. 2015-01-26 15:18:43 +01:00
Bjoern Rabenstein 7e5745fe0e Slim down the files we embed into the binary.
- Use only the minified versions of bootstrap.

- Do not embed non-minified bootstrap files and bootstrap map files.

- Simplify the 'blob-stamp' Makefile contraption.
2015-01-26 15:10:27 +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
juliusv 351a1eb96b Merge pull request #457 from brian-brazil/bootstrap3
Adjust for bootstrap3. Remove long lists from LHS menu.
2015-01-22 15:24:58 +01:00
Brian Brazil 2d8bfa0ced Adjust for bootstrap3. Remove long lists from LHS menu.
Put in a table on the node page instead.
2015-01-22 14:23:22 +00:00
Björn Rabenstein edc91cbabb Merge pull request #456 from prometheus/beorn7/license-cleanup
Clean up license issues.
2015-01-22 14:32:37 +01:00
Stuart Nelson 8ada6360ef Add floats to align inputs, and clear the float on the parent. 2015-01-22 13:27:35 +01:00