mirror of
https://github.com/ClickHouse/ClickHouse.git
synced 2024-11-21 15:12:02 +00:00
test_dictionaries_dependency_xml: decrease dictionaries lifetime
Since ExternalLoader::PeriodicUpdater::check_period_sec = 5, and so if it will be scheduled too early the reload will be skipped, and indeed this is what you can see in logs [1], the reload is done each 10 seconds, not 5: 2021.01.31 14:20:22.590999 [ 48 ] {} <Trace> ExternalDictionariesLoader: Supposed update time for 'dep_x' is 2021-01-31 14:20:27 (loaded, lifetime [5, 5], no errors) 2021.01.31 14:20:22.591016 [ 48 ] {} <Trace> ExternalDictionariesLoader: Next update time for 'dep_x' was set to 2021-01-31 14:20:27 ... 2021.01.31 14:20:32.164882 [ 50 ] {} <Trace> ExternalDictionariesLoader: Start loading object 'dep_x' [1]: https://clickhouse-test-reports.s3.yandex.net/19584/37797fdf5b30dc97147e73b3ac8ca9025b80aaed/integration_tests_(release).html#fail1
This commit is contained in:
parent
9427d5d94b
commit
3d3d6777d3
@ -11,7 +11,8 @@
|
||||
<table>dep_z</table>
|
||||
</clickhouse>
|
||||
</source>
|
||||
<lifetime>5</lifetime>
|
||||
<!-- ExternalLoader::PeriodicUpdater::check_period_sec=5 anyway -->
|
||||
<lifetime>4</lifetime>
|
||||
<layout>
|
||||
<flat/>
|
||||
</layout>
|
||||
|
@ -11,7 +11,8 @@
|
||||
<table>elements</table>
|
||||
</clickhouse>
|
||||
</source>
|
||||
<lifetime>5</lifetime>
|
||||
<!-- ExternalLoader::PeriodicUpdater::check_period_sec=5 anyway -->
|
||||
<lifetime>4</lifetime>
|
||||
<layout>
|
||||
<flat/>
|
||||
</layout>
|
||||
|
@ -12,7 +12,8 @@
|
||||
<invalidate_query>SELECT intDiv(count(), 5) from dict.dep_y</invalidate_query>
|
||||
</clickhouse>
|
||||
</source>
|
||||
<lifetime>5</lifetime>
|
||||
<!-- ExternalLoader::PeriodicUpdater::check_period_sec=5 anyway -->
|
||||
<lifetime>4</lifetime>
|
||||
<layout>
|
||||
<flat/>
|
||||
</layout>
|
||||
|
@ -65,7 +65,7 @@ def test_get_data(started_cluster):
|
||||
assert query("SELECT dictGetString('dep_y', 'a', toUInt64(3))") == "fire\n"
|
||||
assert query("SELECT dictGetString('dep_z', 'a', toUInt64(3))") == "ZZ\n"
|
||||
|
||||
# dep_x and dep_z are updated only when there `intDiv(count(), 4)` is changed.
|
||||
# dep_x and dep_z are updated only when there `intDiv(count(), 5)` is changed.
|
||||
query("INSERT INTO test.elements VALUES (4, 'ether', 404, 0.001)")
|
||||
assert_eq_with_retry(instance, "SELECT dictHas('dep_x', toUInt64(4))", "1", sleep_time=2, retry_count=10)
|
||||
assert query("SELECT dictGetString('dep_x', 'a', toUInt64(3))") == "fire\n"
|
||||
|
Loading…
Reference in New Issue
Block a user