|
24 | 24 |
|
25 | 25 | // Allow to fine tune compactor.
|
26 | 26 | cortex_compactor_max_concurrency: 1,
|
| 27 | + // While this is the default value, we want to pass the same to the -blocks-storage.bucket-store.sync-interval |
| 28 | + cortex_compactor_cleanup_interval: '15m', |
| 29 | + |
| 30 | + // Enable use of bucket index by querier, ruler and store-gateway. |
| 31 | + // Bucket index is generated by compactor from Cortex 1.7, there is no flag required to enable this on compactor. |
| 32 | + cortex_bucket_index_enabled: false, |
27 | 33 | },
|
28 | 34 |
|
29 | 35 | blocks_chunks_caching_config::
|
|
59 | 65 | 'blocks-storage.bucket-store.metadata-cache.memcached.max-get-multi-batch-size': '100',
|
60 | 66 | } else {},
|
61 | 67 |
|
62 |
| - querier_args+:: $.blocks_metadata_caching_config, |
63 |
| - ruler_args+:: $.blocks_metadata_caching_config, |
| 68 | + bucket_index_config:: if $._config.cortex_bucket_index_enabled then { |
| 69 | + 'blocks-storage.bucket-store.bucket-index.enabled': true, |
| 70 | + |
| 71 | + // Bucket index is updated by compactor on each cleanup cycle. |
| 72 | + 'blocks-storage.bucket-store.sync-interval': $._config.cortex_compactor_cleanup_interval, |
| 73 | + } else {}, |
| 74 | + |
| 75 | + querier_args+:: $.blocks_metadata_caching_config + $.bucket_index_config, |
| 76 | + ruler_args+:: $.blocks_metadata_caching_config + $.bucket_index_config, |
64 | 77 |
|
65 | 78 | // The ingesters should persist TSDB blocks and WAL on a persistent
|
66 | 79 | // volume in order to be crash resilient.
|
|
134 | 147 | 'compactor.data-dir': '/data',
|
135 | 148 | 'compactor.compaction-interval': '30m',
|
136 | 149 | 'compactor.compaction-concurrency': $._config.cortex_compactor_max_concurrency,
|
| 150 | + 'compactor.cleanup-interval': $._config.cortex_compactor_cleanup_interval, |
137 | 151 |
|
138 | 152 | // Enable sharding.
|
139 | 153 | 'compactor.sharding-enabled': true,
|
|
189 | 203 | // Persist ring tokens so that when the store-gateway will be restarted
|
190 | 204 | // it will pick the same tokens
|
191 | 205 | 'store-gateway.sharding-ring.tokens-file-path': '/data/tokens',
|
192 |
| - } + $.blocks_chunks_caching_config + $.blocks_metadata_caching_config, |
| 206 | + } + |
| 207 | + $.blocks_chunks_caching_config + |
| 208 | + $.blocks_metadata_caching_config + |
| 209 | + $.bucket_index_config, |
193 | 210 |
|
194 | 211 | store_gateway_ports:: $.util.defaultPorts,
|
195 | 212 |
|
|
0 commit comments