Skip to content

Commit

Permalink
Move a setting to server setting
Browse files Browse the repository at this point in the history
  • Loading branch information
kssenii committed Feb 26, 2024
1 parent f1e95fb commit 05b38b9
Show file tree
Hide file tree
Showing 5 changed files with 5 additions and 10 deletions.
1 change: 0 additions & 1 deletion src/Core/Settings.h
Original file line number Diff line number Diff line change
Expand Up @@ -769,7 +769,6 @@ class IColumn;
M(Bool, enable_filesystem_cache_on_write_operations, false, "Write into cache on write operations. To actually work this setting requires be added to disk config too", 0) \
M(Bool, enable_filesystem_cache_log, false, "Allows to record the filesystem caching log for each query", 0) \
M(Bool, read_from_filesystem_cache_if_exists_otherwise_bypass_cache, false, "Allow to use the filesystem cache in passive mode - benefit from the existing cache entries, but don't put more entries into the cache. If you set this setting for heavy ad-hoc queries and leave it disabled for short real-time queries, this will allows to avoid cache threshing by too heavy queries and to improve the overall system efficiency.", 0) \
M(Bool, force_read_through_cache_for_merges, false, "Force read-through cache for merges", 0) \
M(Bool, skip_download_if_exceeds_query_cache, true, "Skip download from remote filesystem if exceeds query cache size", 0) \
M(UInt64, filesystem_cache_max_download_size, (128UL * 1024 * 1024 * 1024), "Max remote filesystem cache size that can be downloaded by a single query", 0) \
M(Bool, throw_on_error_from_cache_on_write_operations, false, "Ignore error from cache when caching on write operations (INSERT, merges)", 0) \
Expand Down
2 changes: 1 addition & 1 deletion src/Interpreters/Context.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -5079,7 +5079,7 @@ ReadSettings Context::getReadSettings() const
res.read_from_filesystem_cache_if_exists_otherwise_bypass_cache = settings.read_from_filesystem_cache_if_exists_otherwise_bypass_cache;
res.enable_filesystem_cache_log = settings.enable_filesystem_cache_log;
res.filesystem_cache_segments_batch_size = settings.filesystem_cache_segments_batch_size;
res.force_read_through_cache_merges = settings.force_read_through_cache_for_merges;
res.force_read_through_cache_merges = getConfigRef().getBool("force_read_through_cache_for_merges", false);

res.filesystem_cache_max_download_size = settings.filesystem_cache_max_download_size;
res.skip_download_if_exceeds_query_cache = settings.skip_download_if_exceeds_query_cache;
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
<clickhouse>
<force_read_through_cache_for_merges>1</force_read_through_cache_for_merges>
</clickhouse>
2 changes: 1 addition & 1 deletion tests/integration/test_filesystem_cache/test.py
Original file line number Diff line number Diff line change
Expand Up @@ -42,9 +42,9 @@ def cluster():
"node_force_read_through_cache_on_merge",
main_configs=[
"config.d/storage_conf.xml",
"config.d/force_read_through_cache_for_merges.xml",
],
user_configs=[
"users.d/force_read_through_cache_on_merge.xml",
"users.d/cache_on_write_operations.xml",
],
stay_alive=True,
Expand Down

This file was deleted.

0 comments on commit 05b38b9

Please sign in to comment.