mirror of
https://github.com/ClickHouse/ClickHouse.git
synced 2024-11-21 15:12:02 +00:00
Merge pull request #54837 from rschu1ze/obsolete-mt-settings
Mark obsolete settings in system.merge_tree_settings as is_obsolete = 1
This commit is contained in:
commit
6634043a9f
@ -17,7 +17,7 @@ Columns:
|
|||||||
- `0` — Current user can change the setting.
|
- `0` — Current user can change the setting.
|
||||||
- `1` — Current user can’t change the setting.
|
- `1` — Current user can’t change the setting.
|
||||||
- `type` ([String](../../sql-reference/data-types/string.md)) — Setting type (implementation specific string value).
|
- `type` ([String](../../sql-reference/data-types/string.md)) — Setting type (implementation specific string value).
|
||||||
- `is_obsolete` ([UInt8](../../sql-reference/data-types/int-uint.md#uint-ranges)) _ Shows whether a setting is obsolete.
|
- `is_obsolete` ([UInt8](../../sql-reference/data-types/int-uint.md#uint-ranges)) - Shows whether a setting is obsolete.
|
||||||
|
|
||||||
**Example**
|
**Example**
|
||||||
```sql
|
```sql
|
||||||
|
@ -14,7 +14,7 @@ Columns:
|
|||||||
- `changed` ([UInt8](../../sql-reference/data-types/int-uint.md#uint-ranges)) — Shows whether a setting was specified in `config.xml`
|
- `changed` ([UInt8](../../sql-reference/data-types/int-uint.md#uint-ranges)) — Shows whether a setting was specified in `config.xml`
|
||||||
- `description` ([String](../../sql-reference/data-types/string.md)) — Short server setting description.
|
- `description` ([String](../../sql-reference/data-types/string.md)) — Short server setting description.
|
||||||
- `type` ([String](../../sql-reference/data-types/string.md)) — Server setting value type.
|
- `type` ([String](../../sql-reference/data-types/string.md)) — Server setting value type.
|
||||||
- `is_obsolete` ([UInt8](../../sql-reference/data-types/int-uint.md#uint-ranges)) _ Shows whether a setting is obsolete.
|
- `is_obsolete` ([UInt8](../../sql-reference/data-types/int-uint.md#uint-ranges)) - Shows whether a setting is obsolete.
|
||||||
|
|
||||||
**Example**
|
**Example**
|
||||||
|
|
||||||
|
@ -17,7 +17,7 @@ Columns:
|
|||||||
- `0` — Current user can change the setting.
|
- `0` — Current user can change the setting.
|
||||||
- `1` — Current user can’t change the setting.
|
- `1` — Current user can’t change the setting.
|
||||||
- `default` ([String](../../sql-reference/data-types/string.md)) — Setting default value.
|
- `default` ([String](../../sql-reference/data-types/string.md)) — Setting default value.
|
||||||
- `is_obsolete` ([UInt8](../../sql-reference/data-types/int-uint.md#uint-ranges)) _ Shows whether a setting is obsolete.
|
- `is_obsolete` ([UInt8](../../sql-reference/data-types/int-uint.md#uint-ranges)) - Shows whether a setting is obsolete.
|
||||||
|
|
||||||
**Example**
|
**Example**
|
||||||
|
|
||||||
|
@ -804,8 +804,8 @@ class IColumn;
|
|||||||
M(Bool, keeper_map_strict_mode, false, "Enforce additional checks during operations on KeeperMap. E.g. throw an exception on an insert for already existing key", 0) \
|
M(Bool, keeper_map_strict_mode, false, "Enforce additional checks during operations on KeeperMap. E.g. throw an exception on an insert for already existing key", 0) \
|
||||||
M(UInt64, extract_kvp_max_pairs_per_row, 1000, "Max number pairs that can be produced by extractKeyValuePairs function. Used to safeguard against consuming too much memory.", 0) \
|
M(UInt64, extract_kvp_max_pairs_per_row, 1000, "Max number pairs that can be produced by extractKeyValuePairs function. Used to safeguard against consuming too much memory.", 0) \
|
||||||
M(Timezone, session_timezone, "", "This setting can be removed in the future due to potential caveats. It is experimental and is not suitable for production usage. The default timezone for current session or query. The server default timezone if empty.", 0) \
|
M(Timezone, session_timezone, "", "This setting can be removed in the future due to potential caveats. It is experimental and is not suitable for production usage. The default timezone for current session or query. The server default timezone if empty.", 0) \
|
||||||
M(Bool, allow_create_index_without_type, false, "Allow CREATE INDEX query without TYPE. Query will be ignored. Made for SQL compatibility tests.", 0)\
|
M(Bool, allow_create_index_without_type, false, "Allow CREATE INDEX query without TYPE. Query will be ignored. Made for SQL compatibility tests.", 0) \
|
||||||
M(Bool, create_index_ignore_unique, false, "Ignore UNIQUE keyword in CREATE UNIQUE INDEX. Made for SQL compatibility tests.", 0) \
|
M(Bool, create_index_ignore_unique, false, "Ignore UNIQUE keyword in CREATE UNIQUE INDEX. Made for SQL compatibility tests.", 0) \
|
||||||
|
|
||||||
// End of COMMON_SETTINGS
|
// End of COMMON_SETTINGS
|
||||||
// Please add settings related to formats into the FORMAT_FACTORY_SETTINGS, move obsolete settings to OBSOLETE_SETTINGS and obsolete format settings to OBSOLETE_FORMAT_SETTINGS.
|
// Please add settings related to formats into the FORMAT_FACTORY_SETTINGS, move obsolete settings to OBSOLETE_SETTINGS and obsolete format settings to OBSOLETE_FORMAT_SETTINGS.
|
||||||
@ -854,7 +854,7 @@ class IColumn;
|
|||||||
MAKE_DEPRECATED_BY_SERVER_CONFIG(M, UInt64, max_replicated_sends_network_bandwidth_for_server, 0) \
|
MAKE_DEPRECATED_BY_SERVER_CONFIG(M, UInt64, max_replicated_sends_network_bandwidth_for_server, 0) \
|
||||||
/* ---- */ \
|
/* ---- */ \
|
||||||
MAKE_OBSOLETE(M, DefaultDatabaseEngine, default_database_engine, DefaultDatabaseEngine::Atomic) \
|
MAKE_OBSOLETE(M, DefaultDatabaseEngine, default_database_engine, DefaultDatabaseEngine::Atomic) \
|
||||||
MAKE_OBSOLETE(M, UInt64, max_pipeline_depth, 0) \
|
MAKE_OBSOLETE(M, UInt64, max_pipeline_depth, 0) \
|
||||||
MAKE_OBSOLETE(M, Seconds, temporary_live_view_timeout, 1) \
|
MAKE_OBSOLETE(M, Seconds, temporary_live_view_timeout, 1) \
|
||||||
MAKE_OBSOLETE(M, Milliseconds, async_insert_cleanup_timeout_ms, 1000) \
|
MAKE_OBSOLETE(M, Milliseconds, async_insert_cleanup_timeout_ms, 1000) \
|
||||||
MAKE_OBSOLETE(M, Bool, optimize_fuse_sum_count_avg, 0) \
|
MAKE_OBSOLETE(M, Bool, optimize_fuse_sum_count_avg, 0) \
|
||||||
|
@ -24,7 +24,7 @@ struct Settings;
|
|||||||
* and should not be changed by the user without a reason.
|
* and should not be changed by the user without a reason.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
#define LIST_OF_MERGE_TREE_SETTINGS(M, ALIAS) \
|
#define MERGE_TREE_SETTINGS(M, ALIAS) \
|
||||||
M(UInt64, min_compress_block_size, 0, "When granule is written, compress the data in buffer if the size of pending uncompressed data is larger or equal than the specified threshold. If this setting is not set, the corresponding global setting is used.", 0) \
|
M(UInt64, min_compress_block_size, 0, "When granule is written, compress the data in buffer if the size of pending uncompressed data is larger or equal than the specified threshold. If this setting is not set, the corresponding global setting is used.", 0) \
|
||||||
M(UInt64, max_compress_block_size, 0, "Compress the pending uncompressed data in buffer if its size is larger or equal than the specified threshold. Block of data will be compressed even if the current granule is not finished. If this setting is not set, the corresponding global setting is used.", 0) \
|
M(UInt64, max_compress_block_size, 0, "Compress the pending uncompressed data in buffer if its size is larger or equal than the specified threshold. Block of data will be compressed even if the current granule is not finished. If this setting is not set, the corresponding global setting is used.", 0) \
|
||||||
M(UInt64, index_granularity, 8192, "How many rows correspond to one primary key value.", 0) \
|
M(UInt64, index_granularity, 8192, "How many rows correspond to one primary key value.", 0) \
|
||||||
@ -168,6 +168,7 @@ struct Settings;
|
|||||||
M(Bool, allow_vertical_merges_from_compact_to_wide_parts, true, "Allows vertical merges from compact to wide parts. This settings must have the same value on all replicas", 0) \
|
M(Bool, allow_vertical_merges_from_compact_to_wide_parts, true, "Allows vertical merges from compact to wide parts. This settings must have the same value on all replicas", 0) \
|
||||||
M(Bool, enable_the_endpoint_id_with_zookeeper_name_prefix, false, "Enable the endpoint id with zookeeper name prefix for the replicated merge tree table", 0) \
|
M(Bool, enable_the_endpoint_id_with_zookeeper_name_prefix, false, "Enable the endpoint id with zookeeper name prefix for the replicated merge tree table", 0) \
|
||||||
M(UInt64, zero_copy_merge_mutation_min_parts_size_sleep_before_lock, 1ULL * 1024 * 1024 * 1024, "If zero copy replication is enabled sleep random amount of time before trying to lock depending on parts size for merge or mutation", 0) \
|
M(UInt64, zero_copy_merge_mutation_min_parts_size_sleep_before_lock, 1ULL * 1024 * 1024 * 1024, "If zero copy replication is enabled sleep random amount of time before trying to lock depending on parts size for merge or mutation", 0) \
|
||||||
|
M(Bool, allow_floating_point_partition_key, false, "Allow floating point as partition key", 0) \
|
||||||
\
|
\
|
||||||
/** Experimental/work in progress feature. Unsafe for production. */ \
|
/** Experimental/work in progress feature. Unsafe for production. */ \
|
||||||
M(UInt64, part_moves_between_shards_enable, 0, "Experimental/Incomplete feature to move parts between shards. Does not take into account sharding expressions.", 0) \
|
M(UInt64, part_moves_between_shards_enable, 0, "Experimental/Incomplete feature to move parts between shards. Does not take into account sharding expressions.", 0) \
|
||||||
@ -184,32 +185,39 @@ struct Settings;
|
|||||||
M(String, primary_key_compression_codec, "ZSTD(3)", "Compression encoding used by primary, primary key is small enough and cached, so the default compression is ZSTD(3).", 0) \
|
M(String, primary_key_compression_codec, "ZSTD(3)", "Compression encoding used by primary, primary key is small enough and cached, so the default compression is ZSTD(3).", 0) \
|
||||||
M(UInt64, marks_compress_block_size, 65536, "Mark compress block size, the actual size of the block to compress.", 0) \
|
M(UInt64, marks_compress_block_size, 65536, "Mark compress block size, the actual size of the block to compress.", 0) \
|
||||||
M(UInt64, primary_key_compress_block_size, 65536, "Primary compress block size, the actual size of the block to compress.", 0) \
|
M(UInt64, primary_key_compress_block_size, 65536, "Primary compress block size, the actual size of the block to compress.", 0) \
|
||||||
\
|
|
||||||
/** Obsolete settings. Kept for backward compatibility only. */ \
|
#define MAKE_OBSOLETE_MERGE_TREE_SETTING(M, TYPE, NAME, DEFAULT) \
|
||||||
M(UInt64, min_relative_delay_to_yield_leadership, 120, "Obsolete setting, does nothing.", 0) \
|
M(TYPE, NAME, DEFAULT, "Obsolete setting, does nothing.", BaseSettingsHelpers::Flags::OBSOLETE)
|
||||||
M(UInt64, check_delay_period, 60, "Obsolete setting, does nothing.", 0) \
|
|
||||||
M(Bool, allow_floating_point_partition_key, false, "Allow floating point as partition key", 0) \
|
#define OBSOLETE_MERGE_TREE_SETTINGS(M, ALIAS) \
|
||||||
M(UInt64, replicated_max_parallel_sends, 0, "Obsolete setting, does nothing.", 0) \
|
/** Obsolete settings that do nothing but left for compatibility reasons. */ \
|
||||||
M(UInt64, replicated_max_parallel_sends_for_table, 0, "Obsolete setting, does nothing.", 0) \
|
MAKE_OBSOLETE_MERGE_TREE_SETTING(M, UInt64, min_relative_delay_to_yield_leadership, 120) \
|
||||||
M(UInt64, replicated_max_parallel_fetches, 0, "Obsolete setting, does nothing.", 0) \
|
MAKE_OBSOLETE_MERGE_TREE_SETTING(M, UInt64, check_delay_period, 60) \
|
||||||
M(UInt64, replicated_max_parallel_fetches_for_table, 0, "Obsolete setting, does nothing.", 0) \
|
MAKE_OBSOLETE_MERGE_TREE_SETTING(M, UInt64, replicated_max_parallel_sends, 0) \
|
||||||
M(Bool, write_final_mark, true, "Obsolete setting, does nothing.", 0) \
|
MAKE_OBSOLETE_MERGE_TREE_SETTING(M, UInt64, replicated_max_parallel_sends_for_table, 0) \
|
||||||
M(UInt64, min_bytes_for_compact_part, 0, "Obsolete setting, does nothing.", 0) \
|
MAKE_OBSOLETE_MERGE_TREE_SETTING(M, UInt64, replicated_max_parallel_fetches, 0) \
|
||||||
M(UInt64, min_rows_for_compact_part, 0, "Obsolete setting, does nothing.", 0) \
|
MAKE_OBSOLETE_MERGE_TREE_SETTING(M, UInt64, replicated_max_parallel_fetches_for_table, 0) \
|
||||||
M(Bool, in_memory_parts_enable_wal, true, "Obsolete setting, does nothing.", 0) \
|
MAKE_OBSOLETE_MERGE_TREE_SETTING(M, Bool, write_final_mark, true) \
|
||||||
M(UInt64, write_ahead_log_max_bytes, 1024 * 1024 * 1024, "Obsolete setting, does nothing.", 0) \
|
MAKE_OBSOLETE_MERGE_TREE_SETTING(M, UInt64, min_bytes_for_compact_part, 0) \
|
||||||
M(UInt64, write_ahead_log_bytes_to_fsync, 100ULL * 1024 * 1024, "Obsolete setting, does nothing.", 0) \
|
MAKE_OBSOLETE_MERGE_TREE_SETTING(M, UInt64, min_rows_for_compact_part, 0) \
|
||||||
M(UInt64, write_ahead_log_interval_ms_to_fsync, 100, "Obsolete setting, does nothing.", 0) \
|
MAKE_OBSOLETE_MERGE_TREE_SETTING(M, Bool, in_memory_parts_enable_wal, true) \
|
||||||
M(Bool, in_memory_parts_insert_sync, false, "Obsolete setting, does nothing.", 0) \
|
MAKE_OBSOLETE_MERGE_TREE_SETTING(M, UInt64, write_ahead_log_max_bytes, 1024 * 1024 * 1024) \
|
||||||
M(MaxThreads, max_part_loading_threads, 0, "Obsolete setting, does nothing.", 0) \
|
MAKE_OBSOLETE_MERGE_TREE_SETTING(M, UInt64, write_ahead_log_bytes_to_fsync, 100ULL * 1024 * 1024) \
|
||||||
M(MaxThreads, max_part_removal_threads, 0, "Obsolete setting, does nothing.", 0) \
|
MAKE_OBSOLETE_MERGE_TREE_SETTING(M, UInt64, write_ahead_log_interval_ms_to_fsync, 100) \
|
||||||
M(Bool, use_metadata_cache, false, "Obsolete setting, does nothing.", 0) \
|
MAKE_OBSOLETE_MERGE_TREE_SETTING(M, Bool, in_memory_parts_insert_sync, false) \
|
||||||
|
MAKE_OBSOLETE_MERGE_TREE_SETTING(M, MaxThreads, max_part_loading_threads, 0) \
|
||||||
|
MAKE_OBSOLETE_MERGE_TREE_SETTING(M, MaxThreads, max_part_removal_threads, 0) \
|
||||||
|
MAKE_OBSOLETE_MERGE_TREE_SETTING(M, Bool, use_metadata_cache, false) \
|
||||||
|
|
||||||
/// Settings that should not change after the creation of a table.
|
/// Settings that should not change after the creation of a table.
|
||||||
/// NOLINTNEXTLINE
|
/// NOLINTNEXTLINE
|
||||||
#define APPLY_FOR_IMMUTABLE_MERGE_TREE_SETTINGS(M) \
|
#define APPLY_FOR_IMMUTABLE_MERGE_TREE_SETTINGS(M) \
|
||||||
M(index_granularity)
|
M(index_granularity)
|
||||||
|
|
||||||
|
#define LIST_OF_MERGE_TREE_SETTINGS(M, ALIAS) \
|
||||||
|
MERGE_TREE_SETTINGS(M, ALIAS) \
|
||||||
|
OBSOLETE_MERGE_TREE_SETTINGS(M, ALIAS)
|
||||||
|
|
||||||
DECLARE_SETTINGS_TRAITS(MergeTreeSettingsTraits, LIST_OF_MERGE_TREE_SETTINGS)
|
DECLARE_SETTINGS_TRAITS(MergeTreeSettingsTraits, LIST_OF_MERGE_TREE_SETTINGS)
|
||||||
|
|
||||||
|
|
||||||
|
63
tests/queries/0_stateless/02888_obsolete_settings.reference
Normal file
63
tests/queries/0_stateless/02888_obsolete_settings.reference
Normal file
@ -0,0 +1,63 @@
|
|||||||
|
-- Obsolete server settings
|
||||||
|
-- Obsolete general settings
|
||||||
|
allow_experimental_bigint_types
|
||||||
|
allow_experimental_database_atomic
|
||||||
|
allow_experimental_geo_types
|
||||||
|
allow_experimental_map_type
|
||||||
|
allow_experimental_window_functions
|
||||||
|
async_insert_cleanup_timeout_ms
|
||||||
|
async_insert_stale_timeout_ms
|
||||||
|
async_insert_threads
|
||||||
|
background_buffer_flush_schedule_pool_size
|
||||||
|
background_common_pool_size
|
||||||
|
background_distributed_schedule_pool_size
|
||||||
|
background_fetches_pool_size
|
||||||
|
background_merges_mutations_concurrency_ratio
|
||||||
|
background_message_broker_schedule_pool_size
|
||||||
|
background_move_pool_size
|
||||||
|
background_pool_size
|
||||||
|
background_schedule_pool_size
|
||||||
|
backup_threads
|
||||||
|
database_replicated_ddl_output
|
||||||
|
default_database_engine
|
||||||
|
drain_timeout
|
||||||
|
enable_debug_queries
|
||||||
|
handle_kafka_error_mode
|
||||||
|
input_format_arrow_import_nested
|
||||||
|
input_format_orc_import_nested
|
||||||
|
input_format_parquet_import_nested
|
||||||
|
max_alter_threads
|
||||||
|
max_memory_usage_for_all_queries
|
||||||
|
max_pipeline_depth
|
||||||
|
max_remote_read_network_bandwidth_for_server
|
||||||
|
max_remote_write_network_bandwidth_for_server
|
||||||
|
max_replicated_fetches_network_bandwidth_for_server
|
||||||
|
max_replicated_sends_network_bandwidth_for_server
|
||||||
|
merge_tree_clear_old_parts_interval_seconds
|
||||||
|
merge_tree_clear_old_temporary_directories_interval_seconds
|
||||||
|
multiple_joins_rewriter_version
|
||||||
|
odbc_max_field_size
|
||||||
|
optimize_duplicate_order_by_and_distinct
|
||||||
|
optimize_fuse_sum_count_avg
|
||||||
|
partial_merge_join_optimizations
|
||||||
|
replication_alter_columns_timeout
|
||||||
|
restore_threads
|
||||||
|
temporary_live_view_timeout
|
||||||
|
-- Obsolete merge tree settings
|
||||||
|
check_delay_period
|
||||||
|
in_memory_parts_enable_wal
|
||||||
|
in_memory_parts_insert_sync
|
||||||
|
max_part_loading_threads
|
||||||
|
max_part_removal_threads
|
||||||
|
min_bytes_for_compact_part
|
||||||
|
min_relative_delay_to_yield_leadership
|
||||||
|
min_rows_for_compact_part
|
||||||
|
replicated_max_parallel_fetches
|
||||||
|
replicated_max_parallel_fetches_for_table
|
||||||
|
replicated_max_parallel_sends
|
||||||
|
replicated_max_parallel_sends_for_table
|
||||||
|
use_metadata_cache
|
||||||
|
write_ahead_log_bytes_to_fsync
|
||||||
|
write_ahead_log_interval_ms_to_fsync
|
||||||
|
write_ahead_log_max_bytes
|
||||||
|
write_final_mark
|
8
tests/queries/0_stateless/02888_obsolete_settings.sql
Normal file
8
tests/queries/0_stateless/02888_obsolete_settings.sql
Normal file
@ -0,0 +1,8 @@
|
|||||||
|
SELECT '-- Obsolete server settings';
|
||||||
|
SELECT name FROM system.server_settings WHERE is_obsolete = 1 ORDER BY name;
|
||||||
|
|
||||||
|
SELECT '-- Obsolete general settings';
|
||||||
|
SELECT name FROM system.settings WHERE is_obsolete = 1 ORDER BY name;
|
||||||
|
|
||||||
|
SELECT '-- Obsolete merge tree settings';
|
||||||
|
SELECT name FROM system.merge_tree_settings WHERE is_obsolete = 1 ORDER BY name;
|
Loading…
Reference in New Issue
Block a user