Skip to content

Commit

Permalink
Sharding: document supported relabel action and add store gateway bac…
Browse files Browse the repository at this point in the history
…kgroud (#2272)

* Sharding: document supported relabel action and add store gateway background

Signed-off-by: Xiang Dai <764524258@qq.com>

* add hashmod

Signed-off-by: Xiang Dai <764524258@qq.com>
  • Loading branch information
daixiang0 authored Mar 15, 2020
1 parent 081d749 commit b475d33
Showing 1 changed file with 10 additions and 0 deletions.
10 changes: 10 additions & 0 deletions docs/sharding.md
Original file line number Diff line number Diff line change
Expand Up @@ -17,11 +17,21 @@ This means that with time you might want to scale out certain components e.g:

* Compactor: Larger number of objects does not matter much, however compactor has to scale (CPU, network, disk, memory) with number of Sources pushing blocks to the object storage.

* Store Gateway: Queries against store gateway which are touching large number of Sources might be expensive, so it has to scale up with number of Sources if we assume those queries.
* Orthogonally we did not advertise any labels on Store Gateway's Info. This means that querier was not able to do any pre-filtering, so all store gateways in system are always touched for each query.

# Relabelling

Similar to [promtail](https://github.com/grafana/loki/blob/master/docs/promtail.md#scrape-configs) this config will follow native
[Prometheus relabel-config](https://prometheus.io/docs/prometheus/latest/configuration/configuration/#relabel_config) syntax.

Now, thanos only support following relabel actions:
* keep
* drop
* hashmod
* `externa labels` for all components
* `__block_id` for store gateway, see this [example](https://github.com/observatorium/configuration/blob/master/environments/openshift/manifests/observatorium-template.yaml#L1511)

The relabel config defines filtering process done on **every** synchronization with object storage.

We will allow potentially manipulating with several of inputs:
Expand Down

0 comments on commit b475d33

Please sign in to comment.