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
7 changes: 0 additions & 7 deletions programs/local/LocalServer.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -218,9 +218,6 @@ namespace ServerSetting
extern const ServerSettingsUInt64 max_format_parsing_thread_pool_free_size;
extern const ServerSettingsUInt64 format_parsing_thread_pool_queue_size;
extern const ServerSettingsUInt64 cas_blob_upload_pool_size;
extern const ServerSettingsUInt64 max_iceberg_manifest_decode_thread_pool_size;
extern const ServerSettingsUInt64 max_iceberg_manifest_decode_thread_pool_free_size;
extern const ServerSettingsUInt64 iceberg_manifest_decode_thread_pool_queue_size;
extern const ServerSettingsNonZeroUInt64 ai_function_max_thread_pool_size;
extern const ServerSettingsUInt64 ai_function_max_thread_pool_free_size;
extern const ServerSettingsUInt64 ai_function_thread_pool_queue_size;
Expand Down Expand Up @@ -479,10 +476,6 @@ void LocalServer::initialize(Poco::Util::Application & self)
/// pool unconditionally once a `cas` disk commits a part, so every entry point
/// that can run a CA INSERT must initialize it, not only `clickhouse-server`.
DB::Cas::initializeBlobUploadPool(server_settings[ServerSetting::cas_blob_upload_pool_size]);
getIcebergManifestDecodeThreadPool().initialize(
server_settings[ServerSetting::max_iceberg_manifest_decode_thread_pool_size],
server_settings[ServerSetting::max_iceberg_manifest_decode_thread_pool_free_size],
server_settings[ServerSetting::iceberg_manifest_decode_thread_pool_queue_size]);

getAIRequestThreadPool().initialize(
server_settings[ServerSetting::ai_function_max_thread_pool_size],
Expand Down
12 changes: 0 additions & 12 deletions programs/server/Server.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -432,9 +432,6 @@ namespace ServerSetting
extern const ServerSettingsUInt64 max_format_parsing_thread_pool_free_size;
extern const ServerSettingsUInt64 format_parsing_thread_pool_queue_size;
extern const ServerSettingsUInt64 cas_blob_upload_pool_size;
extern const ServerSettingsUInt64 max_iceberg_manifest_decode_thread_pool_size;
extern const ServerSettingsUInt64 max_iceberg_manifest_decode_thread_pool_free_size;
extern const ServerSettingsUInt64 iceberg_manifest_decode_thread_pool_queue_size;
extern const ServerSettingsNonZeroUInt64 ai_function_max_thread_pool_size;
extern const ServerSettingsUInt64 ai_function_max_thread_pool_free_size;
extern const ServerSettingsUInt64 ai_function_thread_pool_queue_size;
Expand Down Expand Up @@ -2014,10 +2011,6 @@ try
server_settings[ServerSetting::format_parsing_thread_pool_queue_size]);

DB::Cas::initializeBlobUploadPool(server_settings[ServerSetting::cas_blob_upload_pool_size]);
getIcebergManifestDecodeThreadPool().initialize(
server_settings[ServerSetting::max_iceberg_manifest_decode_thread_pool_size],
server_settings[ServerSetting::max_iceberg_manifest_decode_thread_pool_free_size],
server_settings[ServerSetting::iceberg_manifest_decode_thread_pool_queue_size]);

getAIRequestThreadPool().initialize(
server_settings[ServerSetting::ai_function_max_thread_pool_size],
Expand Down Expand Up @@ -3081,11 +3074,6 @@ try
new_server_settings[ServerSetting::max_format_parsing_thread_pool_free_size],
new_server_settings[ServerSetting::format_parsing_thread_pool_queue_size]);

getIcebergManifestDecodeThreadPool().reloadConfiguration(
new_server_settings[ServerSetting::max_iceberg_manifest_decode_thread_pool_size],
new_server_settings[ServerSetting::max_iceberg_manifest_decode_thread_pool_free_size],
new_server_settings[ServerSetting::iceberg_manifest_decode_thread_pool_queue_size]);

getAIRequestThreadPool().reloadConfiguration(
new_server_settings[ServerSetting::ai_function_max_thread_pool_size],
new_server_settings[ServerSetting::ai_function_max_thread_pool_free_size],
Expand Down
3 changes: 0 additions & 3 deletions src/Common/CurrentMetrics.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -301,9 +301,6 @@
M(FormatParsingThreads, "Number of threads in the thread pool used for parsing input.") \
M(FormatParsingThreadsActive, "Number of threads in the thread pool used for parsing input running a task.") \
M(FormatParsingThreadsScheduled, "Number of queued or active jobs in the thread pool used for parsing input.") \
M(IcebergManifestDecodeThreads, "Number of threads in the thread pool used for decoding Iceberg data manifest files.") \
M(IcebergManifestDecodeThreadsActive, "Number of threads in the thread pool used for decoding Iceberg data manifest files running a task.") \
M(IcebergManifestDecodeThreadsScheduled, "Number of queued or active jobs in the thread pool used for decoding Iceberg data manifest files.") \
M(OutdatedPartsLoadingThreads, "Number of threads in the threadpool for loading Outdated data parts.") \
M(OutdatedPartsLoadingThreadsActive, "Number of active threads in the threadpool for loading Outdated data parts.") \
M(OutdatedPartsLoadingThreadsScheduled, "Number of queued or active jobs in the threadpool for loading Outdated data parts.") \
Expand Down
1 change: 0 additions & 1 deletion src/Common/setThreadName.h
Original file line number Diff line number Diff line change
Expand Up @@ -81,7 +81,6 @@ namespace DB
M(HASHED_DICT_LOAD, "HashedDictLoad") \
M(HTTP_HANDLER, "HTTPHandler") \
M(HTTP_SERVER_CONN, "HTTPSrvConn") \
M(ICEBERG_DELETE_DECODE, "IcebergDelDec") \
M(ICEBERG_ITERATOR, "IcebergIter") \
M(ICEBERG_SCHEDULE_POOL, "IcebergSchPool") \
M(INTERSERVER_HANDLER, "IntersrvHandler") \
Expand Down
20 changes: 3 additions & 17 deletions src/Core/ServerSettings.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -189,17 +189,9 @@ ClickHouse uses threads from this dedicated server-wide pool to upload blobs in
committing a content-addressed (CAS) part. `cas_blob_upload_pool_size` limits the
maximum number of threads in the pool. Zero is rejected: the pool must have at least one thread.
)", 0) \
DECLARE(UInt64, max_iceberg_manifest_decode_thread_pool_size, 100, R"(
Maximum total number of threads to use for decoding Iceberg data manifest files.

The pool is separate from the IO pool on purpose: a decode task can block until the query consumes the entries it has produced, while the delete manifest decode waits for its tasks on the IO pool before any entry is consumed - sharing one pool could deadlock.
)", 0) \
DECLARE(UInt64, max_iceberg_manifest_decode_thread_pool_free_size, 0, R"(
Maximum number of idle standby threads to keep in the thread pool for decoding Iceberg data manifest files.
)", 0) \
DECLARE(UInt64, iceberg_manifest_decode_thread_pool_queue_size, 10000, R"(
The maximum number of jobs that can be scheduled on the thread pool for decoding Iceberg data manifest files.
)", 0) \
DECLARE(UInt64, max_iceberg_manifest_decode_thread_pool_size, 100, R"(Maximum total number of threads to use for decoding Iceberg data manifest files. The setting is deprecated and has no effect: Iceberg manifest files are read on the IO thread pool.)", SettingsTierType::OBSOLETE) \
DECLARE(UInt64, max_iceberg_manifest_decode_thread_pool_free_size, 0, R"(Maximum number of idle standby threads to keep in the thread pool for decoding Iceberg data manifest files. The setting is deprecated and has no effect: Iceberg manifest files are read on the IO thread pool.)", SettingsTierType::OBSOLETE) \
DECLARE(UInt64, iceberg_manifest_decode_thread_pool_queue_size, 10000, R"(The maximum number of jobs that can be scheduled on the thread pool for decoding Iceberg data manifest files. The setting is deprecated and has no effect: Iceberg manifest files are read on the IO thread pool.)", SettingsTierType::OBSOLETE) \
DECLARE(NonZeroUInt64, ai_function_max_thread_pool_size, 1000, R"(
Maximum total number of threads to use for requests to AI providers. One thread holds one request, so this caps how many AI provider requests the whole server has in flight at once, across all queries. [`ai_function_max_concurrent_requests_per_thread`](/reference/settings/session-settings/ai-function#ai_function_max_concurrent_requests_per_thread) bounds each query thread's share of it.
)", 0) \
Expand Down Expand Up @@ -3712,12 +3704,6 @@ ChangeableSettingsMap collectChangeableServerSettings(ContextPtr context)
{getFormatParsingThreadPool().isInitialized() ? std::to_string(getFormatParsingThreadPool().get().getMaxFreeThreads()) : "0", ChangeableWithoutRestart::Yes}},
{"format_parsing_thread_pool_queue_size",
{getFormatParsingThreadPool().isInitialized() ? std::to_string(getFormatParsingThreadPool().get().getQueueSize()) : "0", ChangeableWithoutRestart::Yes}},
{"max_iceberg_manifest_decode_thread_pool_size",
{getIcebergManifestDecodeThreadPool().isInitialized() ? std::to_string(getIcebergManifestDecodeThreadPool().get().getMaxThreads()) : "0", ChangeableWithoutRestart::Yes}},
{"max_iceberg_manifest_decode_thread_pool_free_size",
{getIcebergManifestDecodeThreadPool().isInitialized() ? std::to_string(getIcebergManifestDecodeThreadPool().get().getMaxFreeThreads()) : "0", ChangeableWithoutRestart::Yes}},
{"iceberg_manifest_decode_thread_pool_queue_size",
{getIcebergManifestDecodeThreadPool().isInitialized() ? std::to_string(getIcebergManifestDecodeThreadPool().get().getQueueSize()) : "0", ChangeableWithoutRestart::Yes}},
{"ai_function_max_thread_pool_size",
{getAIRequestThreadPool().isInitialized() ? std::to_string(getAIRequestThreadPool().get().getMaxThreads()) : "0", ChangeableWithoutRestart::Yes}},
{"ai_function_max_thread_pool_free_size",
Expand Down
21 changes: 4 additions & 17 deletions src/Core/Settings.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -6109,22 +6109,6 @@ Possible values:
)", 0) \
DECLARE(UInt64, iceberg_metadata_staleness_ms, 0, R"(
If non-zero, skip fetching iceberg metadata from remote catalog if there is a cached metadata snapshot, more recent than the given staleness window. Zero means to always fetch the latest metadata version from the remote catalog. Setting this a non-zero trades staleness to a lower latency of read operations.
)", 0) \
DECLARE_WITH_ALIAS(NonZeroUInt64, iceberg_manifest_decode_concurrency, 4, R"(
Maximum number of Iceberg manifest files decoded concurrently while reading a table.

Delete manifests are all decoded before any data file is read; data manifests are decoded while the list of data files for the query is produced, and new ones are decoded only as the query consumes already decoded entries. Decoding several manifests at a time overlaps the object storage round-trips and the per-entry pruning work.

Higher values raise peak memory when the Iceberg metadata files cache is disabled or full, since each in-flight manifest then holds its own decoded contents.

Must be greater than zero; `1` decodes the manifests one at a time.
)", 0, iceberg_delete_manifest_decode_concurrency) \
DECLARE(NonZeroUInt64, iceberg_file_entries_queue_size, 100, R"(
Capacity of the queue between the Iceberg data manifest decode tasks and the query, in data file entries.

The decode tasks pause once the queue is full and the query is not consuming, so this also bounds the read-ahead.

Must be greater than zero.
)", 0) \
DECLARE(Bool, use_parquet_metadata_cache, true, R"(
If turned on, parquet format may utilize the parquet metadata cache.
Expand Down Expand Up @@ -9662,7 +9646,10 @@ Enable experimental table function `eval`.
MAKE_OBSOLETE(M, Bool, query_plan_use_new_logical_join_step, true) \
MAKE_OBSOLETE(M, UInt64, cloud_mode_database_engine, 1) \
MAKE_OBSOLETE(M, Bool, allow_retries_in_cluster_requests, false) \
MAKE_OBSOLETE(M, Bool, allow_named_collection_override_by_default, true)
MAKE_OBSOLETE(M, Bool, allow_named_collection_override_by_default, true) \
MAKE_OBSOLETE(M, NonZeroUInt64, iceberg_manifest_decode_concurrency, 4) \
MAKE_OBSOLETE(M, NonZeroUInt64, iceberg_delete_manifest_decode_concurrency, 4) \
MAKE_OBSOLETE(M, NonZeroUInt64, iceberg_file_entries_queue_size, 100)
/** The section above is for obsolete settings. Do not add anything there. */
#endif /// __CLION_IDE__

Expand Down
1 change: 0 additions & 1 deletion src/IO/SharedThreadPools.h
Original file line number Diff line number Diff line change
Expand Up @@ -71,7 +71,6 @@ class StaticThreadPool
M(MergeTreePrefixesDeserialization, "MergeTreePrefixesDeserializationThreadPool", MergeTreeSubcolumnsReader) \
M(DropDistributedCache, "DropDistributedCacheThreadPool", DropDistributedCache) \
M(FormatParsing, "FormatParsingThreadPool", FormatParsing) \
M(IcebergManifestDecode, "IcebergManifestDecodeThreadPool", IcebergManifestDecode) \
M(ParquetEncoder, "ParquetEncoderThreadPool", ParquetEncoder) \
M(AIRequest, "AIRequestThreadPool", AIRequest)

Expand Down
Loading
Loading