Skip to content

Commit 55bc3dc

Browse files
committed
feat: add migration and distributed settings for ClickHouse configuration
1 parent 036efa0 commit 55bc3dc

File tree

3 files changed

+13
-34
lines changed

3 files changed

+13
-34
lines changed

charts/sentry/Chart.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@ dependencies:
2020
condition: kafka.enabled
2121
- name: clickhouse
2222
repository: oci://registry-1.docker.io/bitnamicharts
23-
version: 9.3.9
23+
version: 4.6.0
2424
condition: clickhouse.enabled
2525
- name: rabbitmq
2626
repository: oci://registry-1.docker.io/bitnamicharts

charts/sentry/templates/snuba/_helper-snuba.tpl

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -33,6 +33,15 @@ settings.py: |
3333

3434
SENTRY_DISTRIBUTED_CLICKHOUSE_TABLES = True
3535

36+
# Migration settings for distributed ClickHouse
37+
MIGRATIONS_LOCK_TIMEOUT = int(env("MIGRATIONS_LOCK_TIMEOUT", "600"))
38+
MIGRATIONS_BATCH_SIZE = int(env("MIGRATIONS_BATCH_SIZE", "1"))
39+
40+
# ClickHouse distributed settings
41+
CLICKHOUSE_MUTATIONS_SYNC = int(env("CLICKHOUSE_MUTATIONS_SYNC", "1"))
42+
CLICKHOUSE_ALTER_SYNC = int(env("CLICKHOUSE_ALTER_SYNC", "1"))
43+
CLICKHOUSE_REPLICATION_ALTER_PARTITIONS_SYNC = int(env("CLICKHOUSE_REPLICATION_ALTER_PARTITIONS_SYNC", "2"))
44+
3645
# Clickhouse Options
3746
CLUSTERS = [
3847
{

charts/sentry/values.yaml

Lines changed: 3 additions & 33 deletions
Original file line numberDiff line numberDiff line change
@@ -254,10 +254,10 @@ sentry:
254254
features:
255255
orgSubdomains: false
256256
vstsLimitedScopes: true
257-
enableProfiling: false
257+
enableProfiling: true
258258
enableSessionReplay: true
259-
enableFeedback: false
260-
enableSpan: false
259+
enableFeedback: true
260+
enableSpan: true
261261

262262
# example customFeature to enable Metrics(beta) https://docs.sentry.io/product/metrics/
263263
# customFeatures:
@@ -2267,36 +2267,6 @@ config:
22672267

22682268
clickhouse:
22692269
enabled: true
2270-
configdFiles:
2271-
99-custom.xml: |
2272-
<clickhouse>
2273-
<logger>
2274-
<level>warning</level>
2275-
<console>true</console>
2276-
</logger>
2277-
<query_thread_log remove="remove"/>
2278-
<query_log remove="remove"/>
2279-
<text_log remove="remove"/>
2280-
<trace_log remove="remove"/>
2281-
<metric_log remove="remove"/>
2282-
<asynchronous_metric_log remove="remove"/>
2283-
2284-
<session_log remove="remove"/>
2285-
<part_log remove="remove"/>
2286-
2287-
<allow_nullable_key>1</allow_nullable_key>
2288-
2289-
<profiles>
2290-
<default>
2291-
<log_queries>0</log_queries>
2292-
<log_query_threads>0</log_query_threads>
2293-
</default>
2294-
</profiles>
2295-
<merge_tree>
2296-
<enable_mixed_granularity_parts>1</enable_mixed_granularity_parts>
2297-
<max_suspicious_broken_parts>10</max_suspicious_broken_parts>
2298-
</merge_tree>
2299-
</clickhouse>
23002270

23012271
## This value is only used when clickhouse.enabled is set to false
23022272
##

0 commit comments

Comments
 (0)