Fix tests

release-11.2-emel
EmelSimsek 2023-06-07 04:44:16 +03:00
parent 4fb2b80f3a
commit beaf692c43
2 changed files with 16 additions and 23 deletions

View File

@ -313,7 +313,13 @@ SELECT create_reference_table('ref_table');
(1 row)
-- add a new node to trigger replicate_reference_tables task
SELECT 1 FROM citus_add_node('localhost', :worker_3_port);
SELECT 1 FROM citus_set_coordinator_host('localhost');
?column?
---------------------------------------------------------------------
1
(1 row)
SELECT 1 FROM master_set_node_property('localhost', :master_port, 'shouldhaveshards', true);
?column?
---------------------------------------------------------------------
1
@ -343,22 +349,12 @@ SELECT state, details from citus_rebalance_status();
(1 row)
RESET ROLE;
-- reset the the number of nodes by removing the previously added node
SELECT 1 FROM citus_drain_node('localhost', :worker_3_port);
NOTICE: Moving shard xxxxx from localhost:xxxxx to localhost:xxxxx ...
?column?
---------------------------------------------------------------------
1
(1 row)
CALL citus_cleanup_orphaned_resources();
NOTICE: cleaned up 1 orphaned resources
SELECT 1 FROM citus_remove_node('localhost', :worker_3_port);
?column?
---------------------------------------------------------------------
1
(1 row)
SET client_min_messages TO WARNING;
DROP SCHEMA background_rebalance CASCADE;
DROP USER non_super_user_rebalance;
SELECT 1 FROM citus_remove_node('localhost', :master_port);
?column?
---------------------------------------------------------------------
1
(1 row)

View File

@ -113,7 +113,8 @@ CREATE TABLE ref_table(a int primary key);
SELECT create_reference_table('ref_table');
-- add a new node to trigger replicate_reference_tables task
SELECT 1 FROM citus_add_node('localhost', :worker_3_port);
SELECT 1 FROM citus_set_coordinator_host('localhost');
SELECT 1 FROM master_set_node_property('localhost', :master_port, 'shouldhaveshards', true);
SET ROLE non_super_user_rebalance;
SELECT 1 FROM citus_rebalance_start(shard_transfer_mode := 'force_logical');
@ -124,11 +125,7 @@ SELECT state, details from citus_rebalance_status();
RESET ROLE;
-- reset the the number of nodes by removing the previously added node
SELECT 1 FROM citus_drain_node('localhost', :worker_3_port);
CALL citus_cleanup_orphaned_resources();
SELECT 1 FROM citus_remove_node('localhost', :worker_3_port);
SET client_min_messages TO WARNING;
DROP SCHEMA background_rebalance CASCADE;
DROP USER non_super_user_rebalance;
SELECT 1 FROM citus_remove_node('localhost', :master_port);