Commit graph

7154 commits

Author SHA1 Message Date
Fabian Reinartz d9fb57cde4 *: Simplify []byte to string unsafe conversion 2017-03-07 11:41:11 +01:00
Fabian Reinartz 2841499212 Simplify and split up iterators
This simplifies some of the iterators by loading chunks from the
ChunkReader earlier, filtering of chunks vs filtering or series is
split into separate iterators for easier testing
2017-03-07 11:30:35 +01:00
Goutham Veeramachaneni 4b0270290b
Fix comments to match convention 2017-03-06 23:21:27 +05:30
Goutham Veeramachaneni c6b329c55b
Support Custom Timeouts for Queries 2017-03-06 23:02:21 +05:30
Fabian Reinartz ed63636de4 Add initial index write/read symmetry test. 2017-03-06 17:36:03 +01:00
Fabian Reinartz 87805fb83f Remove Partitioned* code 2017-03-06 17:34:49 +01:00
Fabian Reinartz eedbebe1d7 Misc cleanups 2017-03-06 14:34:49 +01:00
Fabian Reinartz 50791a412e Remove leaky Appender abstraction for hashedAppend 2017-03-06 14:27:33 +01:00
Goutham Veeramachaneni 6634984a38
Comments and Typo Fixes 2017-03-06 17:16:37 +05:30
Fabian Reinartz 6aee1551e1 Merge pull request #2470 from StephanErb/zk-deadlock
Prevent deadlock in ZK TreeCache constructor by deferring the initial sync.
2017-03-06 12:36:51 +01:00
Fabian Reinartz 87d270fe11 Fix interval check, make DB shutdown concurrent 2017-03-06 12:13:15 +01:00
Michael Kraus 690b49e503 Fix marathon tests 2017-03-06 11:36:55 +01:00
Michael Kraus 31252cc1b5 Clarify explicit use of authorization header 2017-03-06 11:36:36 +01:00
Fabian Reinartz 04783831e2 Correctly close compacted blocks. 2017-03-06 09:33:55 +01:00
Fabian Reinartz 30727b1e71 Vendor compaction changes 2017-03-04 17:42:48 +01:00
Fabian Reinartz 55a9b5428a Add separate head mutex
Introduce a seperate mutex for the head blocks to avoid a race where
a post-compaction reload may run between switching the DB's base mutex
to create a new head block in an appender.
2017-03-04 17:41:01 +01:00
Stephan Erb 3038d0eb9b Prevent deadlock in ZK TreeCache constructor by deferring the initial sync.
Fixes #2254
2017-03-03 23:58:46 +01:00
Erdem Agaoglu 241da87f7f Adding version to names of static files
to prevent browsers using old files in local caches after an upgrade.
2017-03-03 23:36:06 +03:00
Fabian Reinartz 710f3f418f vendor: tsdb compaction changes 2017-03-03 10:06:45 +01:00
Fabian Reinartz 3e569bc964 Optimize memory allocations in writer 2017-03-02 23:35:02 +01:00
Goutham Veeramachaneni af222b63fc
Fix broken tests 2017-03-03 03:16:30 +05:30
Goutham Veeramachaneni f35816613e
Refactored Notifier to use Registerer
* Brought metrics back into Notifier

Notifier still implements a Collector. Check if that is needed.
2017-03-03 02:53:16 +05:30
Fabian Reinartz cc0a7c8279 Create alloc and inuse space heap profile 2017-03-02 21:54:30 +01:00
Fabian Reinartz ffb24a98f4 Add missing unlock, run debug endpoint in benchmark 2017-03-02 21:54:02 +01:00
Goutham Veeramachaneni 41da5c4ef2
Better Metrics For Alerts
* Closes prometheus/prometheus#2429
* Moved metrics to top of file for easier access
* Initialised CounterVecs
2017-03-02 23:58:15 +05:30
Fabian Reinartz 21b97d1e04 Fix compaction selection procedure 2017-03-02 15:10:13 +01:00
Fabian Reinartz 327e07e8d0 Properly sync moves and removes in compactor 2017-03-02 14:35:06 +01:00
Fabian Reinartz 92120448c2 Properly cleanup compacted dirs, fixes, docs 2017-03-02 14:32:09 +01:00
Michael Kraus 04eadf6e20 Allow Marathon SD without bearer_token and bearer_token_file 2017-03-02 13:17:19 +01:00
Michael Kraus 47bdcf0f67 Allow the use of bearer_token or bearer_token_file for MarathonSD 2017-03-02 09:44:20 +01:00
Fabian Reinartz 2c3e778d90 Compactor interface 2017-03-02 09:17:30 +01:00
Fabian Reinartz 9304179ef7 Merge branch 'master' into dev-2.0 2017-03-02 08:16:58 +01:00
Derek Marcotte 0a7fb56b16 Expose PromConsole.Graph.buildQueryUrl, refactor dispatch to use (#2461)
Expose buildQueryUrl, refactor dispatch to use

buildQueryUrl will allow users to execute queries over the range of an
existing graph.  This will be helpful to select data series they wish to
annotate the graph with, for example.
2017-03-01 22:37:50 +00:00
Fabian Reinartz 2c3b56350a Write meta.json file atomically 2017-03-01 17:19:57 +01:00
Fabian Reinartz 6c4217276f Periodically trigger compaction
This addresses an issue where the compaction triggered on cutting
a new block doesn't find anything as the writers are still active on the
block that should be ready for compaction.
2017-03-01 16:52:21 +01:00
Julius Volz 7e14533b32 Merge pull request #2396 from lightpriest/fuzzy-fix-lookup
Fix fuzzy search lookup issues
2017-02-28 19:06:30 +01:00
Erdem Agaoglu 8809735d7f Setting User-Agent header (#2447) 2017-02-28 09:59:33 -04:00
Fabian Reinartz 097a2c1e59 vendor: re-vendor storage 2017-02-28 09:34:30 +01:00
Fabian Reinartz 4397b4d508 *: pass Prometheus registry into storage 2017-02-28 09:33:14 +01:00
Fabian Reinartz db5c88ea9a Misc compaction fixes 2017-02-28 08:40:51 +01:00
Fabian Reinartz b281e4e39b Accept prometheus.Registerer in constructor 2017-02-28 07:26:24 +01:00
Julius Volz 07491c9f1b Merge pull request #2452 from prometheus/swappable-post
notifier: Allow swapping out HTTP Doer
2017-02-27 22:15:24 +01:00
Julius Volz f152ac5e23 notifier: Allow swapping out HTTP Doer
We need to be able to modify the HTTP POST in Weave Cortex to add
multitenancy information to a notification. Since we only really need a
special header in the end, the other option would be to just allow
passing in headers to the notifier. But swapping out the whole Doer is
more general and allows others to swap out the network-talky bits of the
notifier for their own use. Doing this via contexts here wouldn't work
well, due to the decoupled flow of data in the notifier.

There was no existing interface containing the ctxhttp.Post() or
ctxhttp.Do() methods, so I settled on just using Do() as a swappable
function directly (and with a more minimal signature than Post).
2017-02-27 20:36:22 +01:00
Fabian Reinartz 306831f151 Add per-block state ULID 2017-02-27 10:46:15 +01:00
Fabian Reinartz 9a5dfadb09 Tweak IndexWriter interface, serialize directly into dir 2017-02-25 07:24:20 +01:00
Tom Wilkie 1ab893c6ec Limit 'discarding sample' logs to 1 every 10s (#2446)
* Limit 'discarding sample' logs to 1 every 10s

* Include the vendored library

* Review feedback
2017-02-23 19:20:39 +01:00
Fabian Reinartz 78780cd2ba Segment chunk file
This adds write path support for segmented chunk data files.
Files of 512MB are pre-allocated and written to. If the file size
is exceeded, the next file is started. On completion, files
are truncated to their final size.
2017-02-23 10:50:22 +01:00
Julius Volz 16bd5c8ebe Merge pull request #2423 from prometheus/multiple-remote-writers
Re-add multiple remote writers
2017-02-23 09:48:40 +01:00
Fabian Reinartz cc0ff26f1f retrieval: handle GZIP compression ourselves
The automatic GZIP handling of net/http does not preserve
buffers across requests and thus generates a lot of garbage.
We handle GZIP ourselves to circumvent this.t
2017-02-22 13:25:25 +01:00
Julius Volz 2f39dbc8b3 Rename StorageQueueManager -> QueueManager 2017-02-21 21:45:43 +01:00