mirror of https://github.com/citusdata/citus.git
Distribute deprecated dist tables
parent
233230968f
commit
c1149cf4fa
|
@ -970,31 +970,22 @@ SELECT update_distributed_table_colocation('table1_group_none', colocate_with =>
|
||||||
|
|
||||||
(1 row)
|
(1 row)
|
||||||
|
|
||||||
-- sync metadata to get rid of inconsistencies in pg_dist tables
|
-- activate nodes to get rid of inconsistencies in pg_dist tables
|
||||||
select stop_metadata_sync_to_node('localhost', :worker_1_port);
|
INSERT INTO citus.pg_dist_object(classid, objid, objsubid) values('pg_class'::regclass::oid, 'table1_group1'::regclass::oid, 0);
|
||||||
NOTICE: dropping metadata on the node (localhost,57637)
|
INSERT INTO citus.pg_dist_object(classid, objid, objsubid) values('pg_class'::regclass::oid, 'table2_group1'::regclass::oid, 0);
|
||||||
stop_metadata_sync_to_node
|
INSERT INTO citus.pg_dist_object(classid, objid, objsubid) values('pg_class'::regclass::oid, 'table3_group2'::regclass::oid, 0);
|
||||||
|
INSERT INTO citus.pg_dist_object(classid, objid, objsubid) values('pg_class'::regclass::oid, 'table4_group2'::regclass::oid, 0);
|
||||||
|
INSERT INTO citus.pg_dist_object(classid, objid, objsubid) values('pg_class'::regclass::oid, 'table5_groupX'::regclass::oid, 0);
|
||||||
|
select 1 from citus_activate_node('localhost', :worker_1_port);
|
||||||
|
?column?
|
||||||
---------------------------------------------------------------------
|
---------------------------------------------------------------------
|
||||||
|
1
|
||||||
(1 row)
|
(1 row)
|
||||||
|
|
||||||
select stop_metadata_sync_to_node('localhost', :worker_2_port);
|
select 1 from citus_activate_node('localhost', :worker_2_port);
|
||||||
NOTICE: dropping metadata on the node (localhost,57638)
|
?column?
|
||||||
stop_metadata_sync_to_node
|
|
||||||
---------------------------------------------------------------------
|
---------------------------------------------------------------------
|
||||||
|
1
|
||||||
(1 row)
|
|
||||||
|
|
||||||
select start_metadata_sync_to_node('localhost', :worker_1_port);
|
|
||||||
start_metadata_sync_to_node
|
|
||||||
---------------------------------------------------------------------
|
|
||||||
|
|
||||||
(1 row)
|
|
||||||
|
|
||||||
select start_metadata_sync_to_node('localhost', :worker_2_port);
|
|
||||||
start_metadata_sync_to_node
|
|
||||||
---------------------------------------------------------------------
|
|
||||||
|
|
||||||
(1 row)
|
(1 row)
|
||||||
|
|
||||||
-- move a table with a colocation id which is already not in pg_dist_colocation
|
-- move a table with a colocation id which is already not in pg_dist_colocation
|
||||||
|
|
|
@ -410,9 +410,14 @@ SELECT update_distributed_table_colocation('table1_group_none', colocate_with =>
|
||||||
SELECT update_distributed_table_colocation('table1_group_none', colocate_with => 'table2_groupE');
|
SELECT update_distributed_table_colocation('table1_group_none', colocate_with => 'table2_groupE');
|
||||||
SELECT update_distributed_table_colocation('table1_group_none', colocate_with => 'table3_groupE');
|
SELECT update_distributed_table_colocation('table1_group_none', colocate_with => 'table3_groupE');
|
||||||
|
|
||||||
-- activate node to get rid of inconsistencies in pg_dist tables
|
-- activate nodes to get rid of inconsistencies in pg_dist tables
|
||||||
select citus_activate_node('localhost', :worker_1_port);
|
INSERT INTO citus.pg_dist_object(classid, objid, objsubid) values('pg_class'::regclass::oid, 'table1_group1'::regclass::oid, 0);
|
||||||
select citus_activate_node('localhost', :worker_2_port);
|
INSERT INTO citus.pg_dist_object(classid, objid, objsubid) values('pg_class'::regclass::oid, 'table2_group1'::regclass::oid, 0);
|
||||||
|
INSERT INTO citus.pg_dist_object(classid, objid, objsubid) values('pg_class'::regclass::oid, 'table3_group2'::regclass::oid, 0);
|
||||||
|
INSERT INTO citus.pg_dist_object(classid, objid, objsubid) values('pg_class'::regclass::oid, 'table4_group2'::regclass::oid, 0);
|
||||||
|
INSERT INTO citus.pg_dist_object(classid, objid, objsubid) values('pg_class'::regclass::oid, 'table5_groupX'::regclass::oid, 0);
|
||||||
|
select 1 from citus_activate_node('localhost', :worker_1_port);
|
||||||
|
select 1 from citus_activate_node('localhost', :worker_2_port);
|
||||||
|
|
||||||
-- move a table with a colocation id which is already not in pg_dist_colocation
|
-- move a table with a colocation id which is already not in pg_dist_colocation
|
||||||
SELECT update_distributed_table_colocation('table1_group_none', colocate_with => 'table2_group_none');
|
SELECT update_distributed_table_colocation('table1_group_none', colocate_with => 'table2_group_none');
|
||||||
|
|
Loading…
Reference in New Issue