mirror of
https://github.com/ClickHouse/ClickHouse.git
synced 2024-11-22 15:42:02 +00:00
Increase timeout
This commit is contained in:
parent
2556a96e9e
commit
edf0344d0e
@ -83,19 +83,20 @@ def test_reconnect(started_cluster):
|
||||
with PartitionManager() as pm:
|
||||
# Open a connection for insertion.
|
||||
instance.query("INSERT INTO distributed VALUES (1)")
|
||||
time.sleep(0.5)
|
||||
time.sleep(1)
|
||||
assert remote.query("SELECT count(*) FROM local1").strip() == '1'
|
||||
|
||||
# Now break the connection.
|
||||
pm.partition_instances(instance, remote, action='REJECT --reject-with tcp-reset')
|
||||
instance.query("INSERT INTO distributed VALUES (2)")
|
||||
time.sleep(0.5)
|
||||
time.sleep(1)
|
||||
|
||||
# Heal the partition and insert more data.
|
||||
# The connection must be reestablished and after some time all data must be inserted.
|
||||
pm.heal_all()
|
||||
time.sleep(1)
|
||||
instance.query("INSERT INTO distributed VALUES (3)")
|
||||
time.sleep(0.5)
|
||||
time.sleep(1)
|
||||
|
||||
assert remote.query("SELECT count(*) FROM local1").strip() == '3'
|
||||
|
||||
@ -191,4 +192,3 @@ def test_inserts_low_cardinality(started_cluster):
|
||||
instance.query("INSERT INTO low_cardinality_all (d,x,s) VALUES ('2018-11-12',1,'123')")
|
||||
time.sleep(0.5)
|
||||
assert instance.query("SELECT count(*) FROM low_cardinality_all").strip() == '1'
|
||||
|
||||
|
@ -39,7 +39,7 @@ CREATE TABLE distributed (d Date, x UInt32) ENGINE = Distributed('test_cluster',
|
||||
instance_test_inserts_batching.query("CREATE TABLE local2_source (d Date, x UInt32) ENGINE = Log")
|
||||
instance_test_inserts_batching.query("CREATE MATERIALIZED VIEW local2_view to distributed AS SELECT d,x FROM local2_source")
|
||||
|
||||
|
||||
|
||||
instance_test_inserts_local_cluster.query("CREATE TABLE local_source (d Date, x UInt32) ENGINE = Memory")
|
||||
instance_test_inserts_local_cluster.query("CREATE MATERIALIZED VIEW local_view to distributed_on_local AS SELECT d,x FROM local_source")
|
||||
instance_test_inserts_local_cluster.query("CREATE TABLE local (d Date, x UInt32) ENGINE = MergeTree(d, x, 8192)")
|
||||
@ -60,19 +60,21 @@ def test_reconnect(started_cluster):
|
||||
with PartitionManager() as pm:
|
||||
# Open a connection for insertion.
|
||||
instance.query("INSERT INTO local1_source VALUES (1)")
|
||||
time.sleep(0.5)
|
||||
time.sleep(1)
|
||||
assert remote.query("SELECT count(*) FROM local1").strip() == '1'
|
||||
|
||||
# Now break the connection.
|
||||
pm.partition_instances(instance, remote, action='REJECT --reject-with tcp-reset')
|
||||
instance.query("INSERT INTO local1_source VALUES (2)")
|
||||
time.sleep(0.5)
|
||||
time.sleep(1)
|
||||
|
||||
# Heal the partition and insert more data.
|
||||
# The connection must be reestablished and after some time all data must be inserted.
|
||||
pm.heal_all()
|
||||
time.sleep(1)
|
||||
|
||||
instance.query("INSERT INTO local1_source VALUES (3)")
|
||||
time.sleep(0.5)
|
||||
time.sleep(1)
|
||||
|
||||
assert remote.query("SELECT count(*) FROM local1").strip() == '3'
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user