Commit graph

2240 commits

Author SHA1 Message Date
Fabian Reinartz a858c47d9b Add changelog for 0.16.1 2016-01-11 16:48:24 +01:00
Brian Brazil 36dfe3de65 promql: Remove scalar/scalar comparisons.
This change is breaking, use the 'bool' modifier for such comprisons.

After this change all comparisons without 'bool' will filter, and all
comparisons with 'bool' will return 0/1. This makes the language more
consistent and orthogonal, and ultimately easier to learn and use.

If we ever figure out sane semantics for filtering scalar/scalar
comparisons we can add them in, which will most likely come out of how
the new vector() function is used.
2016-01-11 16:48:24 +01:00
Julius Volz 2f728a7be0 Fix and improve build-from-source instructions.
Fixes https://github.com/prometheus/prometheus/issues/1165
2016-01-11 16:48:23 +01:00
Julius Volz d1d2dea8f4 Recompile web assets for autocomplete change. 2016-01-11 16:48:23 +01:00
Julius Volz 0bac481200 Enable autocomplete anywhere in expression.
This enables metric name autocompletion for every word in an expression,
not just the very first one. It would be great to also support all
language keywords during autocompletion in the future.
2016-01-11 16:48:23 +01:00
Jimmi Dyson c81610813e Kubernetes SD: Use node name as instance label 2016-01-11 16:48:23 +01:00
Brian Brazil b48d2b15fb promql: Remove deprecated 2nd argument to delta()
This change is breaking, use increase() instead.

I'm not cleaning up the function in this PR, as my solution to #581 will
rewrite and simplify increase/rate/delta.
2016-01-11 16:48:23 +01:00
Brian Brazil 180b105d75 consoles: Escape regexes.
With the new string handling, some regexes need escaping.
2016-01-11 16:48:23 +01:00
Brian Brazil f69d7a118f promql: Add irate() function
irate is a rate function that only looks at the most
recent two data points, and calucaltes a per-second value
from that. This produces much more granular graphs for
fast moving data, and works sanely across many scrape intervals.

It doesn't do so well for slowly moving data.
2016-01-11 16:48:23 +01:00
Julius Volz 9d3f891be1 Correct date of 0.16.0 release in CHANGELOG.md 2016-01-11 16:48:23 +01:00
Julius Volz 53aed9da89 Cut Prometheus 0.16.0. 2016-01-11 16:48:22 +01:00
Julius Volz f4d79f1376 Fix SD mechanism source prefix handling.
The prefixed target provider changed a pointerized target group that was
reused in the wrapped target provider, causing an ever-increasing chain
of source prefixes in target groups from the Consul target provider.

We now make this bug generally impossible by switching the target group
channel from pointer to value type and thus ensuring that target groups
are copied before being passed on to other parts of the system.

I tried to not let the depointerization leak too far outside of the
channel handling (both upstream and downstream) because I tried that
initially and caused some nasty bugs, which I want to minimize.

Fixes https://github.com/prometheus/prometheus/issues/1083
2016-01-11 16:48:22 +01:00
Julius Volz 5df52e2874 Support escape sequences in strings and add raw strings.
This adapts some functionality from the Go standard library for string
literal lexing and unquoting/unescaping.

The following string types are now supported:

Double- or single-quoted strings:

  These support all escape sequences that Go supports in double-quoted
  string literals. The difference is that Prometheus also has
  single-quoted strings (instead of single-quoted runes in Go). Raw
  newlines are not allowed.

Backtick-quoted raw strings:

  Strings quoted in backticks are treated as raw strings just like in Go
  and may contain raw newlines and other special characters directly.

Fixes https://github.com/prometheus/prometheus/issues/1122
Fixes https://github.com/prometheus/prometheus/issues/1121
2016-01-11 16:48:22 +01:00
Julius Volz c5f927bd65 Add Unquote() strutil function. 2016-01-11 16:48:22 +01:00
Julius Volz aba06b3ed9 Fix watching multiple Zookeeper paths in serverset SD.
Fix https://github.com/prometheus/prometheus/issues/1137
2016-01-11 16:48:22 +01:00
Brian Brazil 4c929a8c78 config: Don't hide username, it's not secret.
Usernames are not generally considered to be secrets,
and treating them as secrets may lead to confusion
as to how secure they are. Obscuring them also makes
debugging harder.
2016-01-11 16:48:22 +01:00
Matt Jibson 9e893a5fee vendor EC2 dependencies 2016-01-11 16:48:22 +01:00
Matt Jibson 1c8b75b98b Add SD for Amazon EC2 instances 2016-01-11 16:48:22 +01:00
Roy Miloh dae8797037 Remove duplicated bootstrap js on the graph template, it's already included on the base template. 2016-01-11 16:48:21 +01:00
Brian Brazil 8a8a3dabea consoles: Remove federation example.
Now that federation is a 1st class feature, there's
no reason to keep this around.
2016-01-11 16:48:21 +01:00
Fabian Reinartz f4ddf1a1d8 Switch to common/log 2016-01-11 16:48:21 +01:00
Thach MAI 734c361f05 Fix example prometheus.yml to use "external_labels" instead of "labels". 2016-01-11 16:48:21 +01:00
Brian Brazil e27d6ecaf2 Mention Hacktoberfest
As DigitalOcean is linking to this page, direct users to the project list from here.
2016-01-11 16:48:21 +01:00
Julius Volz fbb42497af HTML-escape string return values in web UI.
Querying for the string literal "<script>alert(1)</script>" would alert
otherwise.
2016-01-11 16:48:21 +01:00
Julius Volz 46e5472e25 Rename label 'filesystem'->'mountpoint' in node-cpu console.
The label name has been changed in the node exporter.
2016-01-11 16:48:21 +01:00
Fabian Reinartz a52361fdf1 Add missing 'g' 2016-01-11 16:48:21 +01:00
Julius Volz 100d8a951a CHANGELOG.md formatting fixes for 0.16.0rc2 entry 2016-01-11 16:48:20 +01:00
Fabian Reinartz a9e28239ac Cut release 0.16.0rc2 2016-01-11 16:48:20 +01:00
Julius Volz 35fa4ff267 Rename global "labels" config option to "external_labels". 2016-01-11 16:48:20 +01:00
Jimmi Dyson 5028482388 Add Kubernetes namespace & name labels to example config 2016-01-11 16:48:20 +01:00
Jimmi Dyson 88c6da77f9 Kubernetes SD example: separate out cluster level components & services 2016-01-11 16:48:20 +01:00
Jimmi Dyson fb0931d681 Kubernetes SD config tidy & add labelmap action example 2016-01-11 16:48:20 +01:00
Keegan Carruthers-Smith cf5a5a82ac Move InCluster auth in kubernetes example config
CA and Bearer Token are config of `kubernetes_sd_configs`, not the
`scrape_config`. Also updated misleading top-level comment and removed
unnecessary global config.
2016-01-11 16:48:20 +01:00
Julius Volz af661ad76c Fix target manager CPU busyloop caused by bad done-channel handling.
Unfortunately this isn't nicely testable, as it's timing-dependent and
one would have to detect a stray goroutine doing a CPU busyloop...

Fixes https://github.com/prometheus/prometheus/issues/1114
2016-01-11 16:48:20 +01:00
Brian Brazil 10b6d43b3e retrieval: Reduce flakiness of TestTargetRunScraperScrapes 2016-01-11 16:48:20 +01:00
Brian Brazil 0f77856095 retrieval: Add URL parameters to fullLabels too
Move all the special cases into one map, rather than
spreading the logic around.
2016-01-11 16:48:19 +01:00
Fabian Reinartz a4abed1e01 Switch to common/route package 2016-01-11 16:48:19 +01:00
Julius Volz b3ab5ec5d4 Fix / -> /graph redirect when using a path prefix. 2016-01-11 16:48:19 +01:00
Brian Brazil ac72fb75d0 promql: Reduce flakiness of concurrency test 2016-01-11 16:48:19 +01:00
Brian Brazil a7a1200f28 Retrieval: Show error message for failed test scrape
This is flaky, and I suspect it was due the to I/O timeout that I've
already fixed. In case that wasn't it, display the error should it
happen again.
2016-01-11 16:48:19 +01:00
Brian Brazil 1c5fbd568c retrieval: Reduce flakiness of TestTargetManagerChan
This will increase test time by a few hundred ms,
this is the 2nd most common cause of flakiness.
2016-01-11 16:48:19 +01:00
Brian Brazil 99935fdc48 retrieval: Reduce flakiness of target tests
Bump timeouts of tests where we don't want I/O timeouts.

Adjust the full channel test to be much more reliable,
by reducing the ingestion timeout from 1ms to 0.
2016-01-11 16:48:19 +01:00
Fabian Reinartz 2346d9927b Fix nil panic on consul error 2016-01-11 16:48:19 +01:00
Fabian Reinartz 1d8cb6b3e1 Update expfmt.NewDecoder usage 2016-01-11 16:48:18 +01:00
Matt Jibson 9bc4779be2 Allow labelmap action 2016-01-11 16:48:18 +01:00
beorn7 90f594c9fb Fix creation of protobuf fields 2016-01-11 16:48:18 +01:00
Fabian Reinartz 64187e59ce Fix phony targets and log asset generation 2016-01-11 16:48:18 +01:00
Fabian Reinartz 6d5cd89464 Fix unkeyed field errors. 2016-01-11 16:48:18 +01:00
Fabian Reinartz aa020d556c Fix missing return on error 2016-01-11 16:48:18 +01:00
Fabian Reinartz 8eae11da5c Fix scalar construction in function 2016-01-11 16:48:18 +01:00