Skip to content

Commit f723ef3

Browse files
authored
Merge pull request grafana#414 from grafana/chore/tsdb-add-multi-concurrency
tsdb: Add multi concurrency and max idle connections store gateway params
2 parents 591e1f8 + 92d7684 commit f723ef3

File tree

2 files changed

+20
-0
lines changed

2 files changed

+20
-0
lines changed

CHANGELOG.md

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,12 @@
22

33
## master / unreleased
44

5+
* [CHANGE] Store gateway: set `-blocks-storage.bucket-store.index-cache.memcached.max-get-multi-concurrency`,
6+
`-blocks-storage.bucket-store.chunks-cache.memcached.max-get-multi-concurrency`,
7+
`-blocks-storage.bucket-store.metadata-cache.memcached.max-get-multi-concurrency`,
8+
`-blocks-storage.bucket-store.index-cache.memcached.max-idle-connections`,
9+
`-blocks-storage.bucket-store.chunks-cache.memcached.max-idle-connections`,
10+
`-blocks-storage.bucket-store.metadata-cache.memcached.max-idle-connections` to 100 #414
511
* [CHANGE] Update grafana-builder dependency: use $__rate_interval in qpsPanel and latencyPanel. #372
612
* [CHANGE] `namespace` template variable in dashboards now only selects namespaces for selected clusters. #311
713
* [CHANGE] Alertmanager: mounted overrides configmap to alertmanager too. #315

cortex/tsdb.libsonnet

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -223,6 +223,20 @@
223223
'blocks-storage.bucket-store.index-header-lazy-loading-idle-timeout': '60m',
224224

225225
'blocks-storage.bucket-store.max-chunk-pool-bytes': 12 * 1024 * 1024 * 1024,
226+
227+
// We should keep a number of idle connections equal to the max "get" concurrency,
228+
// in order to avoid re-opening connections continuously (this would be slower
229+
// and fill up the conntrack table too).
230+
//
231+
// The downside of this approach is that we'll end up with an higher number of
232+
// active connections to memcached, so we have to make sure connections limit
233+
// set in memcached is high enough.
234+
'blocks-storage.bucket-store.index-cache.memcached.max-get-multi-concurrency': 100,
235+
'blocks-storage.bucket-store.chunks-cache.memcached.max-get-multi-concurrency': 100,
236+
'blocks-storage.bucket-store.metadata-cache.memcached.max-get-multi-concurrency': 100,
237+
'blocks-storage.bucket-store.index-cache.memcached.max-idle-connections': $.store_gateway_args['blocks-storage.bucket-store.index-cache.memcached.max-get-multi-concurrency'],
238+
'blocks-storage.bucket-store.chunks-cache.memcached.max-idle-connections': $.store_gateway_args['blocks-storage.bucket-store.chunks-cache.memcached.max-get-multi-concurrency'],
239+
'blocks-storage.bucket-store.metadata-cache.memcached.max-idle-connections': $.store_gateway_args['blocks-storage.bucket-store.metadata-cache.memcached.max-get-multi-concurrency'],
226240
} +
227241
$.blocks_chunks_caching_config +
228242
$.blocks_metadata_caching_config +

0 commit comments

Comments
 (0)