Karsten Weiss
d79d573f71
Fix spelling mistakes found by codespell ( #4065 )
...
Signed-off-by: Karsten Weiss <knweiss@gmail.com>
2018-04-27 13:04:02 +01:00
Chris Aniszczyk
adb81f943a
Reference non-goals in contributing guidelines ( #4118 )
...
https://github.com/prometheus/docs/issues/149
Signed-off-by: Chris Aniszczyk <caniszczyk@gmail.com>
2018-04-26 22:54:27 +01:00
Sneha Inguva
c1a851074b
promtool: add query instant and query range commands ( #4085 )
...
* promtool: add QueryInstant and QueryRange cmds
* promtool: add more query functions
* promtool: finished query Instant
* promtool: add range query
* promtool: add query command and address arguments
* vendor client and api
2018-04-26 20:41:56 +02:00
Brian Brazil
fbe66819c5
Update ALERTS docs for 2.0 staleness changes. ( #4116 )
...
Signed-off-by: Brian Brazil <brian.brazil@robustperception.io>
2018-04-26 12:44:11 +01:00
Yecheng Fu
2be543e65a
Simplify some code and comments.
...
Signed-off-by: Yecheng Fu <cofyc.jackson@gmail.com>
2018-04-25 19:29:34 +02:00
Yecheng Fu
46683dd67d
Simplify code.
...
- Unified `send` function.
- Pass InformerSynced functions to `cache.WaitForCacheSync`.
- Use `Role\w+` constants instead of literal string.
Signed-off-by: Yecheng Fu <cofyc.jackson@gmail.com>
2018-04-25 19:29:21 +02:00
Yecheng Fu
3a253f796c
Fix grammar in comments and add missing expectedMaxItems
to let it
...
break fast.
Signed-off-by: Yecheng Fu <cofyc.jackson@gmail.com>
2018-04-25 19:29:03 +02:00
Yecheng Fu
d73b0d3141
Move hasSynced interface and its implementations to *_test.go files.
...
Signed-off-by: Yecheng Fu <cofyc.jackson@gmail.com>
2018-04-25 19:28:49 +02:00
Yecheng Fu
8ceb8f2ae8
Refactor Kubernetes Discovery Part 2: Refactoring
...
- Do initial listing and syncing to scrape manager, then register event
handlers may lost events happening in listing and syncing (if it
lasted a long time). We should register event handlers at the very
begining, before processing just wait until informers synced (sync in
informer will list all objects and call OnUpdate event handler).
- Use a queue then we don't block event callbacks and an object will be
processed only once if added multiple times before it being processed.
- Fix bug in `serviceUpdate` in endpoints.go, we should build endpoints
when `exists && err == nil`. Add `^TestEndpointsDiscoveryWithService`
tests to test this feature.
Testing:
- Use `k8s.io/client-go` testing framework and fake implementations which are
more robust and reliable for testing.
- `Test\w+DiscoveryBeforeRun` are used to test objects created before
discoverer runs
- `Test\w+DiscoveryAdd\w+` are used to test adding objects
- `Test\w+DiscoveryDelete\w+` are used to test deleting objects
- `Test\w+DiscoveryUpdate\w+` are used to test updating objects
- `TestEndpointsDiscoveryWithService\w+` are used to test endpoints
events triggered by services
- `cache.DeletedFinalStateUnknown` related stuffs are removed, because
we don't care deleted objects in store, we only need its name to send
a specical `targetgroup.Group` to scrape manager
Signed-off-by: Yecheng Fu <cofyc.jackson@gmail.com>
2018-04-25 19:28:34 +02:00
Yecheng Fu
9bc6ced55d
Refactor Kubernetes Discovery Part 1: Add Vendor files.
...
Signed-off-by: Yecheng Fu <cofyc.jackson@gmail.com>
2018-04-25 19:28:14 +02:00
Adam Shannon
809881d7f5
support reading basic_auth password_file for HTTP basic auth ( #4077 )
...
Issue: https://github.com/prometheus/prometheus/issues/4076
Signed-off-by: Adam Shannon <adamkshannon@gmail.com>
2018-04-25 18:19:06 +01:00
Björn Rabenstein
7cc46bafcb
Merge pull request #4113 from prometheus/beorn7/juggling
...
Fix the merge into release-2.2
2018-04-25 17:09:10 +02:00
Ben Kochie
219433aae5
Update CircleCI build
...
Use CircleCI 2.0 build config.
Signed-off-by: Ben Kochie <superq@gmail.com>
2018-04-25 16:38:05 +02:00
Björn Rabenstein
91e470d733
Merge pull request #4096 from simonpasquier/fix-scrape-races-2.2
...
Fix scrape races (release-2.2 branch)
2018-04-25 15:36:29 +02:00
Ben Kochie
4a4e8a7d3b
Fix spelling in Makefile.common. ( #4105 )
...
Signed-off-by: Ben Kochie <superq@gmail.com>
2018-04-20 19:35:42 +03:00
Ben Kochie
76f6fe8f86
Merge pull request #4102 from krasi-georgiev/makefile
...
run the style target to fail if the code is not properly formatted
2018-04-20 17:30:42 +02:00
Krasi Georgiev
98c51d241b
run the style target to fail if the code is not properly formated
...
Signed-off-by: Krasi Georgiev <kgeorgie@redhat.com>
2018-04-19 15:18:35 +03:00
Krasi Georgiev
0b0c9f4b6b
unused target didn't trigger an error for unused packages ( #4101 )
...
Signed-off-by: Krasi Georgiev <kgeorgie@redhat.com>
2018-04-19 15:07:55 +03:00
Krasi Georgiev
416db814e8
use package shorthand selection that excludes vendored. ( #4100 )
...
Signed-off-by: Krasi Georgiev <kgeorgie@redhat.com>
2018-04-19 13:38:01 +03:00
Krasi Georgiev
3f2b2c50dd
use the Makefile.common ( #3978 )
...
split common targets in a Makefile.common to reuse it across projects
Signed-off-by: Krasi Georgiev <krasi.root@gmail.com>
2018-04-19 12:07:10 +03:00
Simon Pasquier
2cbba4e948
scrape: fix data races
...
This commit avoids passing the full scrape configuration down to the
scrape loop to fix data races when the scrape configuration is being
reloaded.
Signed-off-by: Simon Pasquier <spasquie@redhat.com>
2018-04-18 11:17:31 +02:00
Simon Pasquier
8b89ab0173
scrape: add test detecting data races
...
Signed-off-by: Simon Pasquier <spasquie@redhat.com>
2018-04-18 11:17:25 +02:00
Rohit Gupta
30c3e02864
Fixes #4090 . Marathon service discovery for 5XX http response ( #4091 )
...
Signed-off-by: rohit01 <hello@rohit.io>
2018-04-17 09:28:06 +01:00
Krasi Georgiev
d13db89548
Merge pull request #4073 from krasi-georgiev/remove-unused-vendored
...
remove unused vendored packages
2018-04-17 10:24:01 +03:00
David King
6286c10df0
Fix OOM when a large K is used in topk queries ( #4087 )
...
This attempts to close #3973 .
Handles cases where the length of the input vector to an aggregate topk
/ bottomk function is less than the K paramater. The change updates
Prometheus to allocate a result vector the same length as the input
vector in these cases.
Previously Prometheus would out-of-memory panic for large K values. This
change makes that unlikely unless the size of the input vector is
equally large.
Signed-off-by: David King <dave@davbo.org>
2018-04-16 09:03:04 +01:00
Matt Bostock
def6e5a574
db: Match comment case to function name ( #316 )
...
`validateBlockSequence` is not exported, make the letter case in the comment match the function name.
Signed-off-by: Matt Bostock <matt@mattbostock.com>
2018-04-13 16:50:15 +01:00
Björn Rabenstein
e7584ee345
Merge pull request #4072 from prometheus/beorn7/forward-merge
...
Merge 2.2 bugfixes into master
2018-04-11 13:17:55 +02:00
Krasi Georgiev
7951f6a0f6
Merge pull request #4075 from prometheus/issue-use-case
...
request a use case for proposals
2018-04-11 13:55:06 +03:00
Krasi Georgiev
1467d01147
request a use case for proposals
...
Signed-off-by: Krasi Georgiev <krasi-georgiev@users.noreply.github.com>
2018-04-11 13:47:48 +03:00
Krasi Georgiev
7679bc169d
remove unused vendored packages
...
Signed-off-by: Krasi Georgiev <krasi.root@gmail.com>
2018-04-10 21:22:19 +03:00
beorn7
94ff07b81d
Merge branch 'release-2.2'
...
Signed-off-by: beorn7 <beorn@soundcloud.com>
2018-04-10 16:50:35 +02:00
Björn Rabenstein
f8dcf9b272
Merge pull request #4066 from krasi-georgiev/race-DiscoveredLabels
...
add mutex for DiscoveredLabels
2018-04-10 15:36:56 +02:00
Krasi Georgiev
dc29dd1c6f
add mutex for DiscoveredLabels
...
Signed-off-by: Krasi Georgiev <krasi.root@gmail.com>
2018-04-10 00:18:58 +03:00
Björn Rabenstein
e65fc8591a
Merge pull request #4064 from prometheus/beorn7/vendoring
...
Update vendoring of prometheus/common/route to include data race fix
2018-04-09 17:50:06 +02:00
beorn7
bd44e7fe98
Update vendoring of prometheus/common/route to include data race fix
...
See https://github.com/prometheus/common/pull/125
Signed-off-by: beorn7 <beorn@soundcloud.com>
2018-04-09 17:48:32 +02:00
Krasi Georgiev
ddd46de6f4
Races/3994 ( #4005 )
...
Fix race by properly locking access to scrape pools. Use separate mutex for information needed by UI so that UI isn't blocked when targets are being updated.
2018-04-09 15:18:25 +01:00
Mario Trangoni
464e747f1e
fix some comments typos ( #4059 )
2018-04-08 10:51:54 +01:00
Mario Trangoni
b7173eb0e5
fix some comments typos ( #315 )
2018-04-08 10:28:30 +01:00
Sneha Inguva
cbfb207cca
vendor: correctly update golang client ( #4056 )
2018-04-06 18:05:32 +01:00
Tony Lee
7cd56f56df
add queue_time slice to query_duration_seconds ( #4050 )
2018-04-05 19:56:58 +01:00
Fabian Reinartz
bd832fc827
Merge pull request #314 from Bplotka/overlap-log-improvement
...
db: Made overlap String() prettier and more readable.
2018-04-05 18:20:54 +02:00
Bartek Plotka
00594b85cd
db: Addressed comments.
...
Signed-off-by: Bartek Plotka <bwplotka@gmail.com>
2018-04-05 16:53:24 +01:00
Bartek Plotka
03e94365e1
db: Made overlap String() prettier and more readable.
...
Signed-off-by: Bartek Plotka <bwplotka@gmail.com>
2018-04-05 16:01:16 +01:00
Fabian Reinartz
00e13f519a
Merge pull request #310 from Bplotka/overlap-detection-fix
...
db: Fixed validateBlockSequence, exported it and added tests.
2018-04-05 15:30:22 +02:00
Bartek Plotka
15b5d89222
db: Addressed comments.
...
Signed-off-by: Bartek Plotka <bwplotka@gmail.com>
2018-04-05 14:15:24 +01:00
Bartek Plotka
cc306ef0d5
Added grouping by overlap range.
...
Signed-off-by: Bartek Plotka <bwplotka@gmail.com>
2018-04-05 13:51:33 +01:00
Goutham Veeramachaneni
90d55672d1
Merge pull request #286 from mattbostock/rename_high_timestamp
...
head: Rename highTimestamp to maxt
2018-04-05 17:41:48 +05:30
Goutham Veeramachaneni
d610390427
Merge pull request #312 from gouthamve/nit-1
...
Simplify stones counting.
2018-04-05 17:37:47 +05:30
Julius Volz
fe10b36b30
Fix curl example for deleting series ( #4046 )
2018-04-05 13:06:18 +01:00
sev3ryn
cc917aee7f
fix of endless loop while doing Consul service discovery. ( #4044 )
...
Reloading Prometheus configs doesn't make loop end.
It produced a goroutine leak
2018-04-05 10:41:09 +01:00