fixed regression testing

pull/7958/head
Tiago Silva 2025-04-21 22:08:20 -04:00
parent 0e6127c4f6
commit e03d69f21f
3 changed files with 103 additions and 24 deletions

View File

@ -902,8 +902,42 @@ SELECT id FROM grant_table_propagated_after;
57638 | (grant_on_table.grant_table_propagated_after,id,{grant_user_0=r/postgres}) 57638 | (grant_on_table.grant_table_propagated_after,id,{grant_user_0=r/postgres})
(3 rows) (3 rows)
-- cleanup -- cleanup and test revoke
REVOKE SELECT (id) ON grant_table_propagated_after FROM grant_user_0; SET citus.log_remote_commands TO on;
set citus.grep_remote_commands = '%REVOKE%';
REVOKE SELECT (id) ON grant_table_propagated_after FROM grant_user_0 CASCADE;
NOTICE: issuing REVOKE select (id ) ON grant_table_propagated_after FROM grant_user_0
DETAIL: on server postgres@localhost:xxxxx connectionId: xxxxxxx
NOTICE: issuing REVOKE select (id ) ON grant_table_propagated_after FROM grant_user_0
DETAIL: on server postgres@localhost:xxxxx connectionId: xxxxxxx
NOTICE: issuing SELECT worker_apply_shard_ddl_command (102017, 'grant_on_table', 'REVOKE select (id ) ON grant_table_propagated_after FROM grant_user_0')
DETAIL: on server postgres@localhost:xxxxx connectionId: xxxxxxx
NOTICE: issuing SELECT worker_apply_shard_ddl_command (102018, 'grant_on_table', 'REVOKE select (id ) ON grant_table_propagated_after FROM grant_user_0')
DETAIL: on server postgres@localhost:xxxxx connectionId: xxxxxxx
NOTICE: issuing SELECT worker_apply_shard_ddl_command (102019, 'grant_on_table', 'REVOKE select (id ) ON grant_table_propagated_after FROM grant_user_0')
DETAIL: on server postgres@localhost:xxxxx connectionId: xxxxxxx
NOTICE: issuing SELECT worker_apply_shard_ddl_command (102020, 'grant_on_table', 'REVOKE select (id ) ON grant_table_propagated_after FROM grant_user_0')
DETAIL: on server postgres@localhost:xxxxx connectionId: xxxxxxx
RESET citus.grep_remote_commands;
RESET citus.log_remote_commands;
-- cleanup and test revoke
SET citus.log_remote_commands TO on;
set citus.grep_remote_commands = '%REVOKE%';
REVOKE SELECT (id) ON grant_table_propagated_after FROM grant_user_0 RESTRICT;
NOTICE: issuing REVOKE select (id ) ON grant_table_propagated_after FROM grant_user_0
DETAIL: on server postgres@localhost:xxxxx connectionId: xxxxxxx
NOTICE: issuing REVOKE select (id ) ON grant_table_propagated_after FROM grant_user_0
DETAIL: on server postgres@localhost:xxxxx connectionId: xxxxxxx
NOTICE: issuing SELECT worker_apply_shard_ddl_command (102017, 'grant_on_table', 'REVOKE select (id ) ON grant_table_propagated_after FROM grant_user_0')
DETAIL: on server postgres@localhost:xxxxx connectionId: xxxxxxx
NOTICE: issuing SELECT worker_apply_shard_ddl_command (102018, 'grant_on_table', 'REVOKE select (id ) ON grant_table_propagated_after FROM grant_user_0')
DETAIL: on server postgres@localhost:xxxxx connectionId: xxxxxxx
NOTICE: issuing SELECT worker_apply_shard_ddl_command (102019, 'grant_on_table', 'REVOKE select (id ) ON grant_table_propagated_after FROM grant_user_0')
DETAIL: on server postgres@localhost:xxxxx connectionId: xxxxxxx
NOTICE: issuing SELECT worker_apply_shard_ddl_command (102020, 'grant_on_table', 'REVOKE select (id ) ON grant_table_propagated_after FROM grant_user_0')
DETAIL: on server postgres@localhost:xxxxx connectionId: xxxxxxx
RESET citus.grep_remote_commands;
RESET citus.log_remote_commands;
:verify_grant_table ; :verify_grant_table ;
nodeport | unnest nodeport | unnest
--------------------------------------------------------------------- ---------------------------------------------------------------------

View File

@ -902,8 +902,42 @@ SELECT id FROM grant_table_propagated_after;
57638 | (grant_on_table.grant_table_propagated_after,id,{grant_user_0=r/postgres}) 57638 | (grant_on_table.grant_table_propagated_after,id,{grant_user_0=r/postgres})
(3 rows) (3 rows)
-- cleanup -- cleanup and test revoke
REVOKE SELECT (id) ON grant_table_propagated_after FROM grant_user_0; SET citus.log_remote_commands TO on;
set citus.grep_remote_commands = '%REVOKE%';
REVOKE SELECT (id) ON grant_table_propagated_after FROM grant_user_0 CASCADE;
NOTICE: issuing REVOKE select (id ) ON grant_table_propagated_after FROM grant_user_0
DETAIL: on server postgres@localhost:xxxxx connectionId: xxxxxxx
NOTICE: issuing REVOKE select (id ) ON grant_table_propagated_after FROM grant_user_0
DETAIL: on server postgres@localhost:xxxxx connectionId: xxxxxxx
NOTICE: issuing SELECT worker_apply_shard_ddl_command (102017, 'grant_on_table', 'REVOKE select (id ) ON grant_table_propagated_after FROM grant_user_0')
DETAIL: on server postgres@localhost:xxxxx connectionId: xxxxxxx
NOTICE: issuing SELECT worker_apply_shard_ddl_command (102018, 'grant_on_table', 'REVOKE select (id ) ON grant_table_propagated_after FROM grant_user_0')
DETAIL: on server postgres@localhost:xxxxx connectionId: xxxxxxx
NOTICE: issuing SELECT worker_apply_shard_ddl_command (102019, 'grant_on_table', 'REVOKE select (id ) ON grant_table_propagated_after FROM grant_user_0')
DETAIL: on server postgres@localhost:xxxxx connectionId: xxxxxxx
NOTICE: issuing SELECT worker_apply_shard_ddl_command (102020, 'grant_on_table', 'REVOKE select (id ) ON grant_table_propagated_after FROM grant_user_0')
DETAIL: on server postgres@localhost:xxxxx connectionId: xxxxxxx
RESET citus.grep_remote_commands;
RESET citus.log_remote_commands;
-- cleanup and test revoke
SET citus.log_remote_commands TO on;
set citus.grep_remote_commands = '%REVOKE%';
REVOKE SELECT (id) ON grant_table_propagated_after FROM grant_user_0 RESTRICT;
NOTICE: issuing REVOKE select (id ) ON grant_table_propagated_after FROM grant_user_0
DETAIL: on server postgres@localhost:xxxxx connectionId: xxxxxxx
NOTICE: issuing REVOKE select (id ) ON grant_table_propagated_after FROM grant_user_0
DETAIL: on server postgres@localhost:xxxxx connectionId: xxxxxxx
NOTICE: issuing SELECT worker_apply_shard_ddl_command (102017, 'grant_on_table', 'REVOKE select (id ) ON grant_table_propagated_after FROM grant_user_0')
DETAIL: on server postgres@localhost:xxxxx connectionId: xxxxxxx
NOTICE: issuing SELECT worker_apply_shard_ddl_command (102018, 'grant_on_table', 'REVOKE select (id ) ON grant_table_propagated_after FROM grant_user_0')
DETAIL: on server postgres@localhost:xxxxx connectionId: xxxxxxx
NOTICE: issuing SELECT worker_apply_shard_ddl_command (102019, 'grant_on_table', 'REVOKE select (id ) ON grant_table_propagated_after FROM grant_user_0')
DETAIL: on server postgres@localhost:xxxxx connectionId: xxxxxxx
NOTICE: issuing SELECT worker_apply_shard_ddl_command (102020, 'grant_on_table', 'REVOKE select (id ) ON grant_table_propagated_after FROM grant_user_0')
DETAIL: on server postgres@localhost:xxxxx connectionId: xxxxxxx
RESET citus.grep_remote_commands;
RESET citus.log_remote_commands;
:verify_grant_table ; :verify_grant_table ;
nodeport | unnest nodeport | unnest
--------------------------------------------------------------------- ---------------------------------------------------------------------

View File

@ -424,8 +424,19 @@ SELECT id FROM grant_table_propagated_after;
:verify_grant_table ; :verify_grant_table ;
:verify_grant_attributes ; :verify_grant_attributes ;
-- cleanup -- cleanup and test revoke
REVOKE SELECT (id) ON grant_table_propagated_after FROM grant_user_0; SET citus.log_remote_commands TO on;
set citus.grep_remote_commands = '%REVOKE%';
REVOKE SELECT (id) ON grant_table_propagated_after FROM grant_user_0 CASCADE;
RESET citus.grep_remote_commands;
RESET citus.log_remote_commands;
-- cleanup and test revoke
SET citus.log_remote_commands TO on;
set citus.grep_remote_commands = '%REVOKE%';
REVOKE SELECT (id) ON grant_table_propagated_after FROM grant_user_0 RESTRICT;
RESET citus.grep_remote_commands;
RESET citus.log_remote_commands;
:verify_grant_table ; :verify_grant_table ;
:verify_grant_attributes ; :verify_grant_attributes ;