mirror of https://github.com/citusdata/citus.git
Merge pull request #5576 from citusdata/fix_metadata_sync_fails_on_multi_truncate
Fix metadata sync fails on multi_truncatepull/5555/head^2
commit
c43b6613d0
|
@ -333,6 +333,7 @@ SELECT citus_drop_all_shards('test_local_truncate', 'public', 'test_local_trunca
|
|||
4
|
||||
(1 row)
|
||||
|
||||
CREATE TABLE temp_pg_dist_partition_row AS SELECT * FROM pg_dist_partition WHERE logicalrelid = 'test_local_truncate'::regclass;
|
||||
DELETE FROM pg_dist_partition WHERE logicalrelid = 'test_local_truncate'::regclass;
|
||||
-- Ensure local data is truncated
|
||||
SELECT * FROM test_local_truncate;
|
||||
|
@ -340,7 +341,9 @@ SELECT * FROM test_local_truncate;
|
|||
---------------------------------------------------------------------
|
||||
(0 rows)
|
||||
|
||||
INSERT INTO pg_dist_partition SELECT * FROM temp_pg_dist_partition_row;
|
||||
DROP TABLE test_local_truncate;
|
||||
DROP TABLE temp_pg_dist_partition_row;
|
||||
-- Truncate local data, but roll back
|
||||
CREATE TABLE test_local_truncate (x int, y int);
|
||||
INSERT INTO test_local_truncate VALUES (1,2);
|
||||
|
|
|
@ -247,14 +247,14 @@ test: multi_function_evaluation
|
|||
# ----------
|
||||
# multi_truncate tests truncate functionality for distributed tables
|
||||
# ----------
|
||||
test: check_mx
|
||||
test: turn_mx_off
|
||||
test: multi_truncate
|
||||
|
||||
# ----------
|
||||
# multi_colocation_utils tests utility functions written for co-location feature & internal API
|
||||
# multi_colocated_shard_transfer tests master_copy_shard_placement with colocated tables.
|
||||
# ----------
|
||||
test: check_mx
|
||||
test: turn_mx_off
|
||||
test: multi_colocation_utils
|
||||
test: turn_mx_on
|
||||
test: multi_colocated_shard_transfer
|
||||
|
|
|
@ -206,12 +206,15 @@ SELECT * FROM test_local_truncate;
|
|||
|
||||
-- Undistribute table
|
||||
SELECT citus_drop_all_shards('test_local_truncate', 'public', 'test_local_truncate');
|
||||
CREATE TABLE temp_pg_dist_partition_row AS SELECT * FROM pg_dist_partition WHERE logicalrelid = 'test_local_truncate'::regclass;
|
||||
DELETE FROM pg_dist_partition WHERE logicalrelid = 'test_local_truncate'::regclass;
|
||||
|
||||
-- Ensure local data is truncated
|
||||
SELECT * FROM test_local_truncate;
|
||||
|
||||
INSERT INTO pg_dist_partition SELECT * FROM temp_pg_dist_partition_row;
|
||||
DROP TABLE test_local_truncate;
|
||||
DROP TABLE temp_pg_dist_partition_row;
|
||||
|
||||
-- Truncate local data, but roll back
|
||||
CREATE TABLE test_local_truncate (x int, y int);
|
||||
|
|
Loading…
Reference in New Issue