mirror of
https://github.com/ClickHouse/ClickHouse.git
synced 2024-11-21 15:12:02 +00:00
Merge pull request #71977 from ClickHouse/fix_00098_primary_key_memory_allocated
Fix 00098_primary_key_memory_allocated
This commit is contained in:
commit
5ca9f2e570
@ -988,6 +988,8 @@ void IMergeTreeDataPart::loadIndex() const
|
||||
"{}, read: {})", index_path, marks_count, loaded_index[i]->size());
|
||||
}
|
||||
|
||||
LOG_TEST(storage.log, "Loaded primary key index for part {}, {} columns are kept in memory", name, key_size);
|
||||
|
||||
if (!index_file->eof())
|
||||
throw Exception(ErrorCodes::EXPECTED_END_OF_FILE, "Index file {} is unexpectedly long", index_path);
|
||||
|
||||
|
@ -1 +1 @@
|
||||
1 1 1
|
||||
1 1 1 1
|
||||
|
@ -1 +1,4 @@
|
||||
SELECT primary_key_bytes_in_memory < 16000, primary_key_bytes_in_memory_allocated < 16000, primary_key_bytes_in_memory_allocated / primary_key_bytes_in_memory < 1.1 FROM system.parts WHERE database = 'test' AND table = 'hits';
|
||||
-- Force PK load
|
||||
SELECT CounterID FROM test.hits WHERE CounterID > 0 LIMIT 1 FORMAT Null;
|
||||
-- Check PK size
|
||||
SELECT primary_key_bytes_in_memory > 0, primary_key_bytes_in_memory < 16000, primary_key_bytes_in_memory_allocated < 16000, primary_key_bytes_in_memory_allocated / primary_key_bytes_in_memory < 1.1 FROM system.parts WHERE database = 'test' AND table = 'hits';
|
||||
|
Loading…
Reference in New Issue
Block a user