prometheus/util
Ben Ye 1e4e37144d
Fixed wrongly handled not ready TSDB on web and API. (#7182)
* fix federate endpoint panic

Signed-off-by: yeya24 <yb532204897@gmail.com>

* Fixed all cases of not ready TSDB being wrongly handled.

* Fixed issue for federation.
* Ensured this will never happen again thanks to interfaces
* Fixes same issue for stats.
* Added tests for readiness.
* Fixed bug in stats. It was:
   status.MaxTime = db.Head().MaxTime()
   status.MinTime = db.Head().MaxTime()


Signed-off-by: Bartlomiej Plotka <bwplotka@gmail.com>

* Addressed Brian's comments.

Signed-off-by: Bartlomiej Plotka <bwplotka@gmail.com>

* Addressed Brian's comments.

Signed-off-by: Bartlomiej Plotka <bwplotka@gmail.com>

Co-authored-by: Bartlomiej Plotka <bwplotka@gmail.com>
2020-04-29 17:16:14 +01:00
..
httputil Use struct{} as underlying type for context keys (#6965) 2020-03-11 15:05:35 +01:00
promlint Fix some warnings: 'redundant type from array, slice, or map composite literal' (#7109) 2020-04-15 11:17:41 +01:00
stats Add windows tests for query logger (#6653) 2020-01-20 13:17:11 +00:00
strutil *: enable all default linters (#5504) 2019-05-03 15:11:28 +02:00
teststorage Fixed wrongly handled not ready TSDB on web and API. (#7182) 2020-04-29 17:16:14 +01:00
testutil testutil: Enriched Equals with diff on error. (#7053) 2020-03-26 11:48:23 +02:00
treecache Fix zk connection leak (#5675) 2019-06-21 13:21:13 +01:00