Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,11 @@ final class ClusterClickHouseContainerStarter extends ClickHouseContainerStarter
private static final String NGINX_CONFIG = "containers/nginx/nginx.conf";
private static final String KEEPER_CONFIG = "containers/clickhouse-keeper/keeper_config.xml";
private static final int KEEPER_PORT = 9181;
/**
* Memory limit of each replica container. A server sizes its memory limit and caches from the
* container limit, instead of sizing them for the whole runner.
*/
private static final long NODE_MEMORY_BYTES = 2L * 1024 * 1024 * 1024;

private final GenericContainer<?> keeper;
private final List<GenericContainer<?>> nodes;
Expand Down Expand Up @@ -50,7 +55,8 @@ final class ClusterClickHouseContainerStarter extends ClickHouseContainerStarter
List<GenericContainer<?>> created = new ArrayList<GenericContainer<?>>(NODE_COUNT);
for (int index = 1; index <= NODE_COUNT; index++) {
String name = baseName == null ? null : baseName + "-" + index;
created.add(newClickHouseServer("clickhouse-" + index, name, "r" + index));
created.add(newClickHouseServer("clickhouse-" + index, name, "r" + index)
.withCreateContainerCmdModifier(command -> command.getHostConfig().withMemory(NODE_MEMORY_BYTES)));
}
this.nodes = created;

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -116,4 +116,31 @@
</user_directories>

<allow_experimental_transactions>42</allow_experimental_transactions>

<!-- Of the system logs, tests read only system.query_log. Turn off the others. -->
<!-- Each replica would otherwise flush and merge them all the time. -->
<aggregated_zookeeper_log remove="1"/>
<asynchronous_insert_log remove="1"/>
<asynchronous_metric_log remove="1"/>
<background_schedule_pool_log remove="1"/>
<backup_log remove="1"/>
<blob_storage_log remove="1"/>
<crash_log remove="1"/>
<delta_lake_metadata_log remove="1"/>
<error_log remove="1"/>
<iceberg_metadata_log remove="1"/>
<instrumentation_trace_log remove="1"/>
<metric_log remove="1"/>
<opentelemetry_span_log remove="1"/>
<part_log remove="1"/>
<processors_profile_log remove="1"/>
<query_metric_log remove="1"/>
<query_thread_log remove="1"/>
<query_views_log remove="1"/>
<s3queue_log remove="1"/>
<session_log remove="1"/>
<text_log remove="1"/>
<trace_log remove="1"/>
<zookeeper_connection_log remove="1"/>
<zookeeper_log remove="1"/>
</clickhouse>
Loading