Log username in the failed connection message (#7432)

This patch includes the username in the reported error message.
This makes debugging easier when certain commands open connections
as other users than the user that is executing the command.

```
monitora_snapshot=# SELECT citus_move_shard_placement(102030, 'monitora.db-dev-worker-a', 6005, 'monitora.db-dev-worker-a', 6017);
ERROR:  connection to the remote node monitora_user@monitora.db-dev-worker-a:6017 failed with the following error: fe_sendauth: no password supplied
Time: 40,198 ms
```

(cherry picked from commit 8b48d6ab02)
pull/7588/head
Filip Sedlák 2024-01-24 12:24:23 +01:00 committed by Jelte Fennema-Nio
parent 7513061057
commit fc09e1cfdc
40 changed files with 190 additions and 189 deletions

View File

@ -246,6 +246,7 @@ ClearResultsIfReady(MultiConnection *connection)
void void
ReportConnectionError(MultiConnection *connection, int elevel) ReportConnectionError(MultiConnection *connection, int elevel)
{ {
char *userName = connection->user;
char *nodeName = connection->hostname; char *nodeName = connection->hostname;
int nodePort = connection->port; int nodePort = connection->port;
PGconn *pgConn = connection->pgConn; PGconn *pgConn = connection->pgConn;
@ -264,15 +265,15 @@ ReportConnectionError(MultiConnection *connection, int elevel)
if (messageDetail) if (messageDetail)
{ {
ereport(elevel, (errcode(ERRCODE_CONNECTION_FAILURE), ereport(elevel, (errcode(ERRCODE_CONNECTION_FAILURE),
errmsg("connection to the remote node %s:%d failed with the " errmsg("connection to the remote node %s@%s:%d failed with the "
"following error: %s", nodeName, nodePort, "following error: %s", userName, nodeName, nodePort,
messageDetail))); messageDetail)));
} }
else else
{ {
ereport(elevel, (errcode(ERRCODE_CONNECTION_FAILURE), ereport(elevel, (errcode(ERRCODE_CONNECTION_FAILURE),
errmsg("connection to the remote node %s:%d failed", errmsg("connection to the remote node %s@%s:%d failed",
nodeName, nodePort))); userName, nodeName, nodePort)));
} }
} }

View File

@ -128,7 +128,7 @@ BEGIN;
(1 row) (1 row)
SELECT count(*) FROM socket_test_table; SELECT count(*) FROM socket_test_table;
ERROR: connection to the remote node localhost:xxxxx failed with the following error: connection not open ERROR: connection to the remote node postgres@localhost:xxxxx failed with the following error: connection not open
ROLLBACK; ROLLBACK;
-- repartition joins also can recover -- repartition joins also can recover
SET citus.enable_repartition_joins TO on; SET citus.enable_repartition_joins TO on;

View File

@ -84,7 +84,7 @@ SELECT citus.mitmproxy('conn.connect_delay(1400)');
ALTER TABLE products ADD CONSTRAINT p_key PRIMARY KEY(product_no); ALTER TABLE products ADD CONSTRAINT p_key PRIMARY KEY(product_no);
WARNING: could not establish connection after 900 ms WARNING: could not establish connection after 900 ms
ERROR: connection to the remote node localhost:xxxxx failed ERROR: connection to the remote node postgres@localhost:xxxxx failed
RESET citus.node_connection_timeout; RESET citus.node_connection_timeout;
SELECT citus.mitmproxy('conn.allow()'); SELECT citus.mitmproxy('conn.allow()');
mitmproxy mitmproxy

View File

@ -36,7 +36,7 @@ SELECT citus.mitmproxy('conn.kill()');
(1 row) (1 row)
\COPY test_table FROM stdin delimiter ','; \COPY test_table FROM stdin delimiter ',';
ERROR: connection to the remote node localhost:xxxxx failed with the following error: connection not open ERROR: connection to the remote node postgres@localhost:xxxxx failed with the following error: connection not open
CONTEXT: COPY test_table, line 1: "1,2" CONTEXT: COPY test_table, line 1: "1,2"
SELECT citus.mitmproxy('conn.allow()'); SELECT citus.mitmproxy('conn.allow()');
mitmproxy mitmproxy
@ -271,7 +271,7 @@ SELECT citus.mitmproxy('conn.kill()');
(1 row) (1 row)
\COPY test_table_2 FROM stdin delimiter ','; \COPY test_table_2 FROM stdin delimiter ',';
ERROR: connection to the remote node localhost:xxxxx failed with the following error: connection not open ERROR: connection to the remote node postgres@localhost:xxxxx failed with the following error: connection not open
SELECT citus.mitmproxy('conn.allow()'); SELECT citus.mitmproxy('conn.allow()');
mitmproxy mitmproxy
--------------------------------------------------------------------- ---------------------------------------------------------------------

View File

@ -28,7 +28,7 @@ SELECT citus.mitmproxy('conn.kill()');
(1 row) (1 row)
SELECT create_distributed_table('test_table', 'id'); SELECT create_distributed_table('test_table', 'id');
ERROR: connection to the remote node localhost:xxxxx failed with the following error: connection not open ERROR: connection to the remote node postgres@localhost:xxxxx failed with the following error: connection not open
SELECT count(*) FROM pg_dist_shard WHERE logicalrelid='create_distributed_table_non_empty_failure.test_table'::regclass; SELECT count(*) FROM pg_dist_shard WHERE logicalrelid='create_distributed_table_non_empty_failure.test_table'::regclass;
count count
--------------------------------------------------------------------- ---------------------------------------------------------------------
@ -164,7 +164,7 @@ SELECT citus.mitmproxy('conn.onQuery(query="CREATE TABLE").kill()');
(1 row) (1 row)
SELECT create_distributed_table('test_table', 'id'); SELECT create_distributed_table('test_table', 'id');
ERROR: connection to the remote node localhost:xxxxx failed with the following error: connection not open ERROR: connection to the remote node postgres@localhost:xxxxx failed with the following error: connection not open
SELECT count(*) FROM pg_dist_shard WHERE logicalrelid='create_distributed_table_non_empty_failure.test_table'::regclass; SELECT count(*) FROM pg_dist_shard WHERE logicalrelid='create_distributed_table_non_empty_failure.test_table'::regclass;
count count
--------------------------------------------------------------------- ---------------------------------------------------------------------
@ -436,7 +436,7 @@ SELECT citus.mitmproxy('conn.onQuery(query="^BEGIN TRANSACTION ISOLATION LEVEL R
(1 row) (1 row)
SELECT create_distributed_table('test_table', 'id', colocate_with => 'colocated_table'); SELECT create_distributed_table('test_table', 'id', colocate_with => 'colocated_table');
ERROR: connection to the remote node localhost:xxxxx failed with the following error: connection not open ERROR: connection to the remote node postgres@localhost:xxxxx failed with the following error: connection not open
SELECT count(*) FROM pg_dist_shard WHERE logicalrelid='create_distributed_table_non_empty_failure.test_table'::regclass; SELECT count(*) FROM pg_dist_shard WHERE logicalrelid='create_distributed_table_non_empty_failure.test_table'::regclass;
count count
--------------------------------------------------------------------- ---------------------------------------------------------------------
@ -519,7 +519,7 @@ SELECT citus.mitmproxy('conn.onQuery(query="^SELECT worker_apply_shard_ddl_comma
(1 row) (1 row)
SELECT create_distributed_table('test_table', 'id', colocate_with => 'colocated_table'); SELECT create_distributed_table('test_table', 'id', colocate_with => 'colocated_table');
ERROR: connection to the remote node localhost:xxxxx failed with the following error: connection not open ERROR: connection to the remote node postgres@localhost:xxxxx failed with the following error: connection not open
SELECT count(*) FROM pg_dist_shard WHERE logicalrelid='create_distributed_table_non_empty_failure.test_table'::regclass; SELECT count(*) FROM pg_dist_shard WHERE logicalrelid='create_distributed_table_non_empty_failure.test_table'::regclass;
count count
--------------------------------------------------------------------- ---------------------------------------------------------------------
@ -680,7 +680,7 @@ SELECT citus.mitmproxy('conn.onQuery(query="CREATE TABLE").kill()');
(1 row) (1 row)
SELECT create_distributed_table('test_table', 'id'); SELECT create_distributed_table('test_table', 'id');
ERROR: connection to the remote node localhost:xxxxx failed with the following error: connection not open ERROR: connection to the remote node postgres@localhost:xxxxx failed with the following error: connection not open
SELECT count(*) FROM pg_dist_shard WHERE logicalrelid='create_distributed_table_non_empty_failure.test_table'::regclass; SELECT count(*) FROM pg_dist_shard WHERE logicalrelid='create_distributed_table_non_empty_failure.test_table'::regclass;
count count
--------------------------------------------------------------------- ---------------------------------------------------------------------
@ -901,7 +901,7 @@ SELECT citus.mitmproxy('conn.onQuery(query="^BEGIN TRANSACTION ISOLATION LEVEL R
(1 row) (1 row)
SELECT create_distributed_table('test_table', 'id', colocate_with => 'colocated_table'); SELECT create_distributed_table('test_table', 'id', colocate_with => 'colocated_table');
ERROR: connection to the remote node localhost:xxxxx failed with the following error: connection not open ERROR: connection to the remote node postgres@localhost:xxxxx failed with the following error: connection not open
SELECT count(*) FROM pg_dist_shard WHERE logicalrelid='create_distributed_table_non_empty_failure.test_table'::regclass; SELECT count(*) FROM pg_dist_shard WHERE logicalrelid='create_distributed_table_non_empty_failure.test_table'::regclass;
count count
--------------------------------------------------------------------- ---------------------------------------------------------------------

View File

@ -27,8 +27,8 @@ SELECT citus.mitmproxy('conn.onQuery(query="CREATE").kill()');
CREATE INDEX CONCURRENTLY idx_index_test ON index_test(id, value_1); CREATE INDEX CONCURRENTLY idx_index_test ON index_test(id, value_1);
WARNING: CONCURRENTLY-enabled index commands can fail partially, leaving behind an INVALID index. WARNING: CONCURRENTLY-enabled index commands can fail partially, leaving behind an INVALID index.
Use DROP INDEX CONCURRENTLY IF EXISTS to remove the invalid index. Use DROP INDEX CONCURRENTLY IF EXISTS to remove the invalid index.
ERROR: connection to the remote node localhost:xxxxx failed with the following error: connection not open ERROR: connection to the remote node postgres@localhost:xxxxx failed with the following error: connection not open
SELECT citus.mitmproxy('conn.allow()'); SELECT citus.mitmproxy('conn.allow()');
mitmproxy mitmproxy
--------------------------------------------------------------------- ---------------------------------------------------------------------
@ -60,8 +60,8 @@ SELECT citus.mitmproxy('conn.onQuery(query="CREATE").kill()');
CREATE INDEX CONCURRENTLY idx_index_test ON index_test(id, value_1); CREATE INDEX CONCURRENTLY idx_index_test ON index_test(id, value_1);
WARNING: CONCURRENTLY-enabled index commands can fail partially, leaving behind an INVALID index. WARNING: CONCURRENTLY-enabled index commands can fail partially, leaving behind an INVALID index.
Use DROP INDEX CONCURRENTLY IF EXISTS to remove the invalid index. Use DROP INDEX CONCURRENTLY IF EXISTS to remove the invalid index.
ERROR: connection to the remote node localhost:xxxxx failed with the following error: connection not open ERROR: connection to the remote node postgres@localhost:xxxxx failed with the following error: connection not open
SELECT citus.mitmproxy('conn.allow()'); SELECT citus.mitmproxy('conn.allow()');
mitmproxy mitmproxy
--------------------------------------------------------------------- ---------------------------------------------------------------------
@ -87,7 +87,7 @@ SELECT citus.mitmproxy('conn.onQuery(query="CREATE").cancel(' || pg_backend_pid(
CREATE INDEX CONCURRENTLY idx_index_test ON index_test(id, value_1); CREATE INDEX CONCURRENTLY idx_index_test ON index_test(id, value_1);
WARNING: CONCURRENTLY-enabled index commands can fail partially, leaving behind an INVALID index. WARNING: CONCURRENTLY-enabled index commands can fail partially, leaving behind an INVALID index.
Use DROP INDEX CONCURRENTLY IF EXISTS to remove the invalid index. Use DROP INDEX CONCURRENTLY IF EXISTS to remove the invalid index.
ERROR: canceling statement due to user request ERROR: canceling statement due to user request
SELECT citus.mitmproxy('conn.allow()'); SELECT citus.mitmproxy('conn.allow()');
mitmproxy mitmproxy
@ -112,7 +112,7 @@ SELECT citus.mitmproxy('conn.onQuery(query="CREATE").cancel(' || pg_backend_pid(
CREATE INDEX CONCURRENTLY idx_index_test ON index_test(id, value_1); CREATE INDEX CONCURRENTLY idx_index_test ON index_test(id, value_1);
WARNING: CONCURRENTLY-enabled index commands can fail partially, leaving behind an INVALID index. WARNING: CONCURRENTLY-enabled index commands can fail partially, leaving behind an INVALID index.
Use DROP INDEX CONCURRENTLY IF EXISTS to remove the invalid index. Use DROP INDEX CONCURRENTLY IF EXISTS to remove the invalid index.
ERROR: canceling statement due to user request ERROR: canceling statement due to user request
SELECT citus.mitmproxy('conn.allow()'); SELECT citus.mitmproxy('conn.allow()');
mitmproxy mitmproxy
@ -138,8 +138,8 @@ SELECT citus.mitmproxy('conn.onQuery(query="DROP INDEX CONCURRENTLY").kill()');
DROP INDEX CONCURRENTLY IF EXISTS idx_index_test; DROP INDEX CONCURRENTLY IF EXISTS idx_index_test;
WARNING: CONCURRENTLY-enabled index commands can fail partially, leaving behind an INVALID index. WARNING: CONCURRENTLY-enabled index commands can fail partially, leaving behind an INVALID index.
Use DROP INDEX CONCURRENTLY IF EXISTS to remove the invalid index. Use DROP INDEX CONCURRENTLY IF EXISTS to remove the invalid index.
ERROR: connection to the remote node localhost:xxxxx failed with the following error: connection not open ERROR: connection to the remote node postgres@localhost:xxxxx failed with the following error: connection not open
SELECT citus.mitmproxy('conn.allow()'); SELECT citus.mitmproxy('conn.allow()');
mitmproxy mitmproxy
--------------------------------------------------------------------- ---------------------------------------------------------------------
@ -165,7 +165,7 @@ SELECT create_distributed_table('index_test_2', 'a');
INSERT INTO index_test_2 VALUES (1, 1), (1, 2); INSERT INTO index_test_2 VALUES (1, 1), (1, 2);
CREATE UNIQUE INDEX CONCURRENTLY index_test_2_a_idx ON index_test_2(a); CREATE UNIQUE INDEX CONCURRENTLY index_test_2_a_idx ON index_test_2(a);
WARNING: CONCURRENTLY-enabled index commands can fail partially, leaving behind an INVALID index. WARNING: CONCURRENTLY-enabled index commands can fail partially, leaving behind an INVALID index.
Use DROP INDEX CONCURRENTLY IF EXISTS to remove the invalid index. Use DROP INDEX CONCURRENTLY IF EXISTS to remove the invalid index.
ERROR: could not create unique index "index_test_2_a_idx_1880019" ERROR: could not create unique index "index_test_2_a_idx_1880019"
DETAIL: Key (a)=(1) is duplicated. DETAIL: Key (a)=(1) is duplicated.
CONTEXT: while executing command on localhost:xxxxx CONTEXT: while executing command on localhost:xxxxx

View File

@ -22,7 +22,7 @@ SELECT citus.mitmproxy('conn.kill()');
(1 row) (1 row)
SELECT create_distributed_table('test_table','id'); SELECT create_distributed_table('test_table','id');
ERROR: connection to the remote node localhost:xxxxx failed with the following error: connection not open ERROR: connection to the remote node postgres@localhost:xxxxx failed with the following error: connection not open
SELECT citus.mitmproxy('conn.allow()'); SELECT citus.mitmproxy('conn.allow()');
mitmproxy mitmproxy
--------------------------------------------------------------------- ---------------------------------------------------------------------
@ -116,7 +116,7 @@ SELECT citus.mitmproxy('conn.onQuery(query="SELECT worker_apply_shard_ddl_comman
(1 row) (1 row)
SELECT create_distributed_table('test_table','id'); SELECT create_distributed_table('test_table','id');
ERROR: connection to the remote node localhost:xxxxx failed with the following error: connection not open ERROR: connection to the remote node postgres@localhost:xxxxx failed with the following error: connection not open
SELECT citus.mitmproxy('conn.allow()'); SELECT citus.mitmproxy('conn.allow()');
mitmproxy mitmproxy
--------------------------------------------------------------------- ---------------------------------------------------------------------
@ -147,7 +147,7 @@ BEGIN;
(1 row) (1 row)
SELECT create_distributed_table('test_table', 'id'); SELECT create_distributed_table('test_table', 'id');
ERROR: connection to the remote node localhost:xxxxx failed with the following error: connection not open ERROR: connection to the remote node postgres@localhost:xxxxx failed with the following error: connection not open
COMMIT; COMMIT;
SELECT citus.mitmproxy('conn.allow()'); SELECT citus.mitmproxy('conn.allow()');
mitmproxy mitmproxy
@ -215,7 +215,7 @@ SELECT citus.mitmproxy('conn.onQuery(query="CREATE TABLE").kill()');
(1 row) (1 row)
SELECT create_distributed_table('test_table','id',colocate_with=>'temp_table'); SELECT create_distributed_table('test_table','id',colocate_with=>'temp_table');
ERROR: connection to the remote node localhost:xxxxx failed with the following error: connection not open ERROR: connection to the remote node postgres@localhost:xxxxx failed with the following error: connection not open
SELECT citus.mitmproxy('conn.allow()'); SELECT citus.mitmproxy('conn.allow()');
mitmproxy mitmproxy
--------------------------------------------------------------------- ---------------------------------------------------------------------
@ -484,7 +484,7 @@ SELECT citus.mitmproxy('conn.onQuery(query="CREATE TABLE").kill()');
BEGIN; BEGIN;
SELECT create_distributed_table('test_table','id'); SELECT create_distributed_table('test_table','id');
ERROR: connection to the remote node localhost:xxxxx failed with the following error: connection not open ERROR: connection to the remote node postgres@localhost:xxxxx failed with the following error: connection not open
ROLLBACK; ROLLBACK;
SELECT citus.mitmproxy('conn.allow()'); SELECT citus.mitmproxy('conn.allow()');
mitmproxy mitmproxy

View File

@ -86,7 +86,7 @@ FROM
ORDER BY 1 DESC LIMIT 5 ORDER BY 1 DESC LIMIT 5
) as foo ) as foo
WHERE foo.user_id = cte.user_id; WHERE foo.user_id = cte.user_id;
ERROR: connection to the remote node localhost:xxxxx failed with the following error: connection not open ERROR: connection to the remote node postgres@localhost:xxxxx failed with the following error: connection not open
-- kill at the third copy (pull) -- kill at the third copy (pull)
SELECT citus.mitmproxy('conn.onQuery(query="SELECT DISTINCT users_table.user").kill()'); SELECT citus.mitmproxy('conn.onQuery(query="SELECT DISTINCT users_table.user").kill()');
mitmproxy mitmproxy
@ -117,7 +117,7 @@ FROM
ORDER BY 1 DESC LIMIT 5 ORDER BY 1 DESC LIMIT 5
) as foo ) as foo
WHERE foo.user_id = cte.user_id; WHERE foo.user_id = cte.user_id;
ERROR: connection to the remote node localhost:xxxxx failed with the following error: connection not open ERROR: connection to the remote node postgres@localhost:xxxxx failed with the following error: connection not open
-- cancel at the first copy (push) -- cancel at the first copy (push)
SELECT citus.mitmproxy('conn.onQuery(query="^COPY").cancel(' || :pid || ')'); SELECT citus.mitmproxy('conn.onQuery(query="^COPY").cancel(' || :pid || ')');
mitmproxy mitmproxy
@ -254,7 +254,7 @@ SELECT citus.mitmproxy('conn.onQuery(query="^DELETE FROM").kill()');
WITH cte_delete AS MATERIALIZED (DELETE FROM users_table WHERE user_name in ('A', 'D') RETURNING *) WITH cte_delete AS MATERIALIZED (DELETE FROM users_table WHERE user_name in ('A', 'D') RETURNING *)
INSERT INTO users_table SELECT * FROM cte_delete; INSERT INTO users_table SELECT * FROM cte_delete;
ERROR: connection to the remote node localhost:xxxxx failed with the following error: connection not open ERROR: connection to the remote node postgres@localhost:xxxxx failed with the following error: connection not open
-- verify contents are the same -- verify contents are the same
SELECT citus.mitmproxy('conn.allow()'); SELECT citus.mitmproxy('conn.allow()');
mitmproxy mitmproxy
@ -365,7 +365,7 @@ BEGIN;
SET LOCAL citus.multi_shard_modify_mode = 'sequential'; SET LOCAL citus.multi_shard_modify_mode = 'sequential';
WITH cte_delete AS MATERIALIZED (DELETE FROM users_table WHERE user_name in ('A', 'D') RETURNING *) WITH cte_delete AS MATERIALIZED (DELETE FROM users_table WHERE user_name in ('A', 'D') RETURNING *)
INSERT INTO users_table SELECT * FROM cte_delete; INSERT INTO users_table SELECT * FROM cte_delete;
ERROR: connection to the remote node localhost:xxxxx failed with the following error: connection not open ERROR: connection to the remote node postgres@localhost:xxxxx failed with the following error: connection not open
END; END;
RESET SEARCH_PATH; RESET SEARCH_PATH;
SELECT citus.mitmproxy('conn.allow()'); SELECT citus.mitmproxy('conn.allow()');

View File

@ -36,7 +36,7 @@ SELECT citus.mitmproxy('conn.onAuthenticationOk().kill()');
(1 row) (1 row)
ALTER TABLE test_table ADD COLUMN new_column INT; ALTER TABLE test_table ADD COLUMN new_column INT;
ERROR: connection to the remote node localhost:xxxxx failed with the following error: connection not open ERROR: connection to the remote node postgres@localhost:xxxxx failed with the following error: connection not open
SELECT array_agg(name::text ORDER BY name::text) FROM public.table_attrs where relid = 'test_table'::regclass; SELECT array_agg(name::text ORDER BY name::text) FROM public.table_attrs where relid = 'test_table'::regclass;
array_agg array_agg
--------------------------------------------------------------------- ---------------------------------------------------------------------
@ -99,7 +99,7 @@ SELECT citus.mitmproxy('conn.onQuery(query="worker_apply_shard_ddl_command").kil
(1 row) (1 row)
ALTER TABLE test_table ADD COLUMN new_column INT; ALTER TABLE test_table ADD COLUMN new_column INT;
ERROR: connection to the remote node localhost:xxxxx failed with the following error: connection not open ERROR: connection to the remote node postgres@localhost:xxxxx failed with the following error: connection not open
-- show that we've never commited the changes -- show that we've never commited the changes
SELECT array_agg(name::text ORDER BY name::text) FROM public.table_attrs where relid = 'test_table'::regclass; SELECT array_agg(name::text ORDER BY name::text) FROM public.table_attrs where relid = 'test_table'::regclass;
array_agg array_agg
@ -300,7 +300,7 @@ SELECT citus.mitmproxy('conn.onAuthenticationOk().kill()');
(1 row) (1 row)
ALTER TABLE test_table DROP COLUMN new_column; ALTER TABLE test_table DROP COLUMN new_column;
ERROR: connection to the remote node localhost:xxxxx failed with the following error: connection not open ERROR: connection to the remote node postgres@localhost:xxxxx failed with the following error: connection not open
SELECT array_agg(name::text ORDER BY name::text) FROM public.table_attrs where relid = 'test_table'::regclass; SELECT array_agg(name::text ORDER BY name::text) FROM public.table_attrs where relid = 'test_table'::regclass;
array_agg array_agg
--------------------------------------------------------------------- ---------------------------------------------------------------------
@ -361,7 +361,7 @@ SELECT citus.mitmproxy('conn.onQuery(query="worker_apply_shard_ddl_command").kil
(1 row) (1 row)
ALTER TABLE test_table DROP COLUMN new_column; ALTER TABLE test_table DROP COLUMN new_column;
ERROR: connection to the remote node localhost:xxxxx failed with the following error: connection not open ERROR: connection to the remote node postgres@localhost:xxxxx failed with the following error: connection not open
SELECT array_agg(name::text ORDER BY name::text) FROM public.table_attrs where relid = 'test_table'::regclass; SELECT array_agg(name::text ORDER BY name::text) FROM public.table_attrs where relid = 'test_table'::regclass;
array_agg array_agg
--------------------------------------------------------------------- ---------------------------------------------------------------------
@ -661,7 +661,7 @@ SELECT citus.mitmproxy('conn.onAuthenticationOk().kill()');
(1 row) (1 row)
ALTER TABLE test_table ADD COLUMN new_column INT; ALTER TABLE test_table ADD COLUMN new_column INT;
ERROR: connection to the remote node localhost:xxxxx failed with the following error: connection not open ERROR: connection to the remote node postgres@localhost:xxxxx failed with the following error: connection not open
SELECT array_agg(name::text ORDER BY name::text) FROM public.table_attrs where relid = 'test_table'::regclass; SELECT array_agg(name::text ORDER BY name::text) FROM public.table_attrs where relid = 'test_table'::regclass;
array_agg array_agg
--------------------------------------------------------------------- ---------------------------------------------------------------------
@ -722,7 +722,7 @@ SELECT citus.mitmproxy('conn.onQuery(query="worker_apply_shard_ddl_command").kil
(1 row) (1 row)
ALTER TABLE test_table ADD COLUMN new_column INT; ALTER TABLE test_table ADD COLUMN new_column INT;
ERROR: connection to the remote node localhost:xxxxx failed with the following error: connection not open ERROR: connection to the remote node postgres@localhost:xxxxx failed with the following error: connection not open
SELECT array_agg(name::text ORDER BY name::text) FROM public.table_attrs where relid = 'test_table'::regclass; SELECT array_agg(name::text ORDER BY name::text) FROM public.table_attrs where relid = 'test_table'::regclass;
array_agg array_agg
--------------------------------------------------------------------- ---------------------------------------------------------------------
@ -1010,7 +1010,7 @@ SELECT citus.mitmproxy('conn.onQuery(query="worker_apply_shard_ddl_command").kil
(1 row) (1 row)
ALTER TABLE test_table ADD COLUMN new_column INT; ALTER TABLE test_table ADD COLUMN new_column INT;
ERROR: connection to the remote node localhost:xxxxx failed with the following error: connection not open ERROR: connection to the remote node postgres@localhost:xxxxx failed with the following error: connection not open
-- kill as soon as the coordinator after it sends worker_apply_shard_ddl_command 2nd time -- kill as soon as the coordinator after it sends worker_apply_shard_ddl_command 2nd time
SELECT citus.mitmproxy('conn.onQuery(query="worker_apply_shard_ddl_command").after(2).kill()'); SELECT citus.mitmproxy('conn.onQuery(query="worker_apply_shard_ddl_command").after(2).kill()');
mitmproxy mitmproxy
@ -1019,7 +1019,7 @@ SELECT citus.mitmproxy('conn.onQuery(query="worker_apply_shard_ddl_command").aft
(1 row) (1 row)
ALTER TABLE test_table ADD COLUMN new_column INT; ALTER TABLE test_table ADD COLUMN new_column INT;
ERROR: connection to the remote node localhost:xxxxx failed with the following error: connection not open ERROR: connection to the remote node postgres@localhost:xxxxx failed with the following error: connection not open
-- cancel as soon as the coordinator after it sends worker_apply_shard_ddl_command 2nd time -- cancel as soon as the coordinator after it sends worker_apply_shard_ddl_command 2nd time
SELECT citus.mitmproxy('conn.onQuery(query="worker_apply_shard_ddl_command").after(2).cancel(' || pg_backend_pid() || ')'); SELECT citus.mitmproxy('conn.onQuery(query="worker_apply_shard_ddl_command").after(2).cancel(' || pg_backend_pid() || ')');
mitmproxy mitmproxy

View File

@ -86,7 +86,7 @@ CREATE TABLE distributed_result_info AS
SELECT resultId, nodeport, rowcount, targetShardId, targetShardIndex SELECT resultId, nodeport, rowcount, targetShardId, targetShardIndex
FROM partition_task_list_results('test', $$ SELECT * FROM source_table $$, 'target_table') FROM partition_task_list_results('test', $$ SELECT * FROM source_table $$, 'target_table')
NATURAL JOIN pg_dist_node; NATURAL JOIN pg_dist_node;
WARNING: connection to the remote node localhost:xxxxx failed with the following error: connection not open WARNING: connection to the remote node postgres@localhost:xxxxx failed with the following error: connection not open
SELECT * FROM distributed_result_info ORDER BY resultId; SELECT * FROM distributed_result_info ORDER BY resultId;
resultid | nodeport | rowcount | targetshardid | targetshardindex resultid | nodeport | rowcount | targetshardid | targetshardindex
--------------------------------------------------------------------- ---------------------------------------------------------------------

View File

@ -101,7 +101,7 @@ NOTICE: issuing SELECT count(*) AS count FROM failure_failover_to_local_executi
DETAIL: on server postgres@localhost:xxxxx connectionId: xxxxxxx DETAIL: on server postgres@localhost:xxxxx connectionId: xxxxxxx
NOTICE: issuing SELECT count(*) AS count FROM failure_failover_to_local_execution.failover_to_local_1980003 failover_to_local WHERE true NOTICE: issuing SELECT count(*) AS count FROM failure_failover_to_local_execution.failover_to_local_1980003 failover_to_local WHERE true
DETAIL: on server postgres@localhost:xxxxx connectionId: xxxxxxx DETAIL: on server postgres@localhost:xxxxx connectionId: xxxxxxx
WARNING: connection to the remote node localhost:xxxxx failed with the following error: connection not open WARNING: connection to the remote node postgres@localhost:xxxxx failed with the following error: connection not open
NOTICE: executing the command locally: SELECT count(*) AS count FROM failure_failover_to_local_execution.failover_to_local_1980000 failover_to_local WHERE true NOTICE: executing the command locally: SELECT count(*) AS count FROM failure_failover_to_local_execution.failover_to_local_1980000 failover_to_local WHERE true
NOTICE: executing the command locally: SELECT count(*) AS count FROM failure_failover_to_local_execution.failover_to_local_1980002 failover_to_local WHERE true NOTICE: executing the command locally: SELECT count(*) AS count FROM failure_failover_to_local_execution.failover_to_local_1980002 failover_to_local WHERE true
count count

View File

@ -44,7 +44,7 @@ SELECT citus.mitmproxy('conn.onQuery(query="^INSERT INTO insert_select_pushdown"
(1 row) (1 row)
INSERT INTO events_summary SELECT user_id, event_id, count(*) FROM events_table GROUP BY 1,2; INSERT INTO events_summary SELECT user_id, event_id, count(*) FROM events_table GROUP BY 1,2;
ERROR: connection to the remote node localhost:xxxxx failed with the following error: connection not open ERROR: connection to the remote node postgres@localhost:xxxxx failed with the following error: connection not open
--verify nothing is modified --verify nothing is modified
SELECT citus.mitmproxy('conn.allow()'); SELECT citus.mitmproxy('conn.allow()');
mitmproxy mitmproxy
@ -95,7 +95,7 @@ SELECT citus.mitmproxy('conn.onQuery(query="^INSERT INTO insert_select_pushdown"
(1 row) (1 row)
INSERT INTO events_table SELECT * FROM events_table; INSERT INTO events_table SELECT * FROM events_table;
ERROR: connection to the remote node localhost:xxxxx failed with the following error: connection not open ERROR: connection to the remote node postgres@localhost:xxxxx failed with the following error: connection not open
--verify nothing is modified --verify nothing is modified
SELECT citus.mitmproxy('conn.allow()'); SELECT citus.mitmproxy('conn.allow()');
mitmproxy mitmproxy

View File

@ -55,7 +55,7 @@ SELECT citus.mitmproxy('conn.onQuery(query="worker_partition_query_result").kill
(1 row) (1 row)
INSERT INTO target_table SELECT * FROM source_table; INSERT INTO target_table SELECT * FROM source_table;
ERROR: connection to the remote node localhost:xxxxx failed with the following error: connection not open ERROR: connection to the remote node postgres@localhost:xxxxx failed with the following error: connection not open
SELECT * FROM target_table ORDER BY a; SELECT * FROM target_table ORDER BY a;
a | b a | b
--------------------------------------------------------------------- ---------------------------------------------------------------------
@ -68,7 +68,7 @@ SELECT citus.mitmproxy('conn.onQuery(query="worker_partition_query_result").kill
(1 row) (1 row)
INSERT INTO target_table SELECT * FROM replicated_source_table; INSERT INTO target_table SELECT * FROM replicated_source_table;
WARNING: connection to the remote node localhost:xxxxx failed with the following error: connection not open WARNING: connection to the remote node postgres@localhost:xxxxx failed with the following error: connection not open
SELECT * FROM target_table ORDER BY a; SELECT * FROM target_table ORDER BY a;
a | b a | b
--------------------------------------------------------------------- ---------------------------------------------------------------------
@ -138,7 +138,7 @@ SELECT citus.mitmproxy('conn.onQuery(query="read_intermediate_results").kill()')
(1 row) (1 row)
INSERT INTO target_table SELECT * FROM source_table; INSERT INTO target_table SELECT * FROM source_table;
ERROR: connection to the remote node localhost:xxxxx failed with the following error: connection not open ERROR: connection to the remote node postgres@localhost:xxxxx failed with the following error: connection not open
SELECT * FROM target_table ORDER BY a; SELECT * FROM target_table ORDER BY a;
a | b a | b
--------------------------------------------------------------------- ---------------------------------------------------------------------
@ -151,7 +151,7 @@ SELECT citus.mitmproxy('conn.onQuery(query="read_intermediate_results").kill()')
(1 row) (1 row)
INSERT INTO target_table SELECT * FROM replicated_source_table; INSERT INTO target_table SELECT * FROM replicated_source_table;
ERROR: connection to the remote node localhost:xxxxx failed with the following error: connection not open ERROR: connection to the remote node postgres@localhost:xxxxx failed with the following error: connection not open
SELECT * FROM target_table ORDER BY a; SELECT * FROM target_table ORDER BY a;
a | b a | b
--------------------------------------------------------------------- ---------------------------------------------------------------------
@ -168,7 +168,7 @@ SELECT citus.mitmproxy('conn.onQuery(query="read_intermediate_results").kill()')
(1 row) (1 row)
INSERT INTO replicated_target_table SELECT * FROM source_table; INSERT INTO replicated_target_table SELECT * FROM source_table;
ERROR: connection to the remote node localhost:xxxxx failed with the following error: connection not open ERROR: connection to the remote node postgres@localhost:xxxxx failed with the following error: connection not open
SELECT * FROM replicated_target_table; SELECT * FROM replicated_target_table;
a | b a | b
--------------------------------------------------------------------- ---------------------------------------------------------------------

View File

@ -33,7 +33,7 @@ SELECT citus.mitmproxy('conn.onQuery(query="DELETE").kill()');
BEGIN; BEGIN;
DELETE FROM dml_test WHERE id = 1; DELETE FROM dml_test WHERE id = 1;
ERROR: connection to the remote node localhost:xxxxx failed with the following error: connection not open ERROR: connection to the remote node postgres@localhost:xxxxx failed with the following error: connection not open
DELETE FROM dml_test WHERE id = 2; DELETE FROM dml_test WHERE id = 2;
ERROR: current transaction is aborted, commands ignored until end of transaction block ERROR: current transaction is aborted, commands ignored until end of transaction block
INSERT INTO dml_test VALUES (5, 'Epsilon'); INSERT INTO dml_test VALUES (5, 'Epsilon');
@ -93,7 +93,7 @@ BEGIN;
DELETE FROM dml_test WHERE id = 1; DELETE FROM dml_test WHERE id = 1;
DELETE FROM dml_test WHERE id = 2; DELETE FROM dml_test WHERE id = 2;
INSERT INTO dml_test VALUES (5, 'Epsilon'); INSERT INTO dml_test VALUES (5, 'Epsilon');
ERROR: connection to the remote node localhost:xxxxx failed with the following error: connection not open ERROR: connection to the remote node postgres@localhost:xxxxx failed with the following error: connection not open
UPDATE dml_test SET name = 'alpha' WHERE id = 1; UPDATE dml_test SET name = 'alpha' WHERE id = 1;
ERROR: current transaction is aborted, commands ignored until end of transaction block ERROR: current transaction is aborted, commands ignored until end of transaction block
UPDATE dml_test SET name = 'gamma' WHERE id = 3; UPDATE dml_test SET name = 'gamma' WHERE id = 3;
@ -148,7 +148,7 @@ DELETE FROM dml_test WHERE id = 1;
DELETE FROM dml_test WHERE id = 2; DELETE FROM dml_test WHERE id = 2;
INSERT INTO dml_test VALUES (5, 'Epsilon'); INSERT INTO dml_test VALUES (5, 'Epsilon');
UPDATE dml_test SET name = 'alpha' WHERE id = 1; UPDATE dml_test SET name = 'alpha' WHERE id = 1;
ERROR: connection to the remote node localhost:xxxxx failed with the following error: connection not open ERROR: connection to the remote node postgres@localhost:xxxxx failed with the following error: connection not open
UPDATE dml_test SET name = 'gamma' WHERE id = 3; UPDATE dml_test SET name = 'gamma' WHERE id = 3;
ERROR: current transaction is aborted, commands ignored until end of transaction block ERROR: current transaction is aborted, commands ignored until end of transaction block
COMMIT; COMMIT;

View File

@ -43,7 +43,7 @@ SELECT citus.mitmproxy('conn.onQuery(query="INSERT").kill()');
(1 row) (1 row)
INSERT INTO distributed_table VALUES (1,1), (1,2), (1,3); INSERT INTO distributed_table VALUES (1,1), (1,2), (1,3);
ERROR: connection to the remote node localhost:xxxxx failed with the following error: connection not open ERROR: connection to the remote node postgres@localhost:xxxxx failed with the following error: connection not open
-- this test is broken, see https://github.com/citusdata/citus/issues/2460 -- this test is broken, see https://github.com/citusdata/citus/issues/2460
-- SELECT citus.mitmproxy('conn.onQuery(query="^INSERT").cancel(' || :pid || ')'); -- SELECT citus.mitmproxy('conn.onQuery(query="^INSERT").cancel(' || :pid || ')');
-- INSERT INTO distributed_table VALUES (1,4), (1,5), (1,6); -- INSERT INTO distributed_table VALUES (1,4), (1,5), (1,6);
@ -55,7 +55,7 @@ SELECT citus.mitmproxy('conn.onQuery(query="^INSERT").kill()');
(1 row) (1 row)
INSERT INTO distributed_table VALUES (1,7), (5,8); INSERT INTO distributed_table VALUES (1,7), (5,8);
ERROR: connection to the remote node localhost:xxxxx failed with the following error: connection not open ERROR: connection to the remote node postgres@localhost:xxxxx failed with the following error: connection not open
-- this test is broken, see https://github.com/citusdata/citus/issues/2460 -- this test is broken, see https://github.com/citusdata/citus/issues/2460
-- SELECT citus.mitmproxy('conn.onQuery(query="^INSERT").cancel(' || :pid || ')'); -- SELECT citus.mitmproxy('conn.onQuery(query="^INSERT").cancel(' || :pid || ')');
-- INSERT INTO distributed_table VALUES (1,9), (5,10); -- INSERT INTO distributed_table VALUES (1,9), (5,10);
@ -67,7 +67,7 @@ SELECT citus.mitmproxy('conn.onQuery(query="^INSERT").kill()');
(1 row) (1 row)
INSERT INTO distributed_table VALUES (1,11), (6,12); INSERT INTO distributed_table VALUES (1,11), (6,12);
ERROR: connection to the remote node localhost:xxxxx failed with the following error: connection not open ERROR: connection to the remote node postgres@localhost:xxxxx failed with the following error: connection not open
SELECT citus.mitmproxy('conn.onQuery(query="^INSERT").cancel(' || :pid || ')'); SELECT citus.mitmproxy('conn.onQuery(query="^INSERT").cancel(' || :pid || ')');
mitmproxy mitmproxy
--------------------------------------------------------------------- ---------------------------------------------------------------------
@ -84,7 +84,7 @@ SELECT citus.mitmproxy('conn.onQuery(query="^INSERT").after(1).kill()');
(1 row) (1 row)
INSERT INTO distributed_table VALUES (1,15), (6,16); INSERT INTO distributed_table VALUES (1,15), (6,16);
ERROR: connection to the remote node localhost:xxxxx failed with the following error: connection not open ERROR: connection to the remote node postgres@localhost:xxxxx failed with the following error: connection not open
SELECT citus.mitmproxy('conn.onQuery(query="^INSERT").after(1).cancel(' || :pid || ')'); SELECT citus.mitmproxy('conn.onQuery(query="^INSERT").after(1).cancel(' || :pid || ')');
mitmproxy mitmproxy
--------------------------------------------------------------------- ---------------------------------------------------------------------
@ -101,7 +101,7 @@ SELECT citus.mitmproxy('conn.onQuery(query="^INSERT").kill()');
(1 row) (1 row)
INSERT INTO distributed_table VALUES (2,19),(1,20); INSERT INTO distributed_table VALUES (2,19),(1,20);
ERROR: connection to the remote node localhost:xxxxx failed with the following error: connection not open ERROR: connection to the remote node postgres@localhost:xxxxx failed with the following error: connection not open
SELECT citus.mitmproxy('conn.onQuery(query="^INSERT").cancel(' || :pid || ')'); SELECT citus.mitmproxy('conn.onQuery(query="^INSERT").cancel(' || :pid || ')');
mitmproxy mitmproxy
--------------------------------------------------------------------- ---------------------------------------------------------------------

View File

@ -58,7 +58,7 @@ SELECT citus.mitmproxy('conn.onQuery(query="DELETE FROM").kill()');
-- issue a multi shard delete -- issue a multi shard delete
DELETE FROM t2 WHERE b = 2; DELETE FROM t2 WHERE b = 2;
ERROR: connection to the remote node localhost:xxxxx failed with the following error: connection not open ERROR: connection to the remote node postgres@localhost:xxxxx failed with the following error: connection not open
-- verify nothing is deleted -- verify nothing is deleted
SELECT count(*) FROM t2; SELECT count(*) FROM t2;
count count
@ -74,7 +74,7 @@ SELECT citus.mitmproxy('conn.onQuery(query="DELETE FROM multi_shard.t2_201005").
(1 row) (1 row)
DELETE FROM t2 WHERE b = 2; DELETE FROM t2 WHERE b = 2;
ERROR: connection to the remote node localhost:xxxxx failed with the following error: connection not open ERROR: connection to the remote node postgres@localhost:xxxxx failed with the following error: connection not open
-- verify nothing is deleted -- verify nothing is deleted
SELECT count(*) FROM t2; SELECT count(*) FROM t2;
count count
@ -134,7 +134,7 @@ SELECT citus.mitmproxy('conn.onQuery(query="^UPDATE").kill()');
-- issue a multi shard update -- issue a multi shard update
UPDATE t2 SET c = 4 WHERE b = 2; UPDATE t2 SET c = 4 WHERE b = 2;
ERROR: connection to the remote node localhost:xxxxx failed with the following error: connection not open ERROR: connection to the remote node postgres@localhost:xxxxx failed with the following error: connection not open
-- verify nothing is updated -- verify nothing is updated
SELECT count(*) FILTER (WHERE b = 2) AS b2, count(*) FILTER (WHERE c = 4) AS c4 FROM t2; SELECT count(*) FILTER (WHERE b = 2) AS b2, count(*) FILTER (WHERE c = 4) AS c4 FROM t2;
b2 | c4 b2 | c4
@ -150,7 +150,7 @@ SELECT citus.mitmproxy('conn.onQuery(query="UPDATE multi_shard.t2_201005").kill(
(1 row) (1 row)
UPDATE t2 SET c = 4 WHERE b = 2; UPDATE t2 SET c = 4 WHERE b = 2;
ERROR: connection to the remote node localhost:xxxxx failed with the following error: connection not open ERROR: connection to the remote node postgres@localhost:xxxxx failed with the following error: connection not open
-- verify nothing is updated -- verify nothing is updated
SELECT count(*) FILTER (WHERE b = 2) AS b2, count(*) FILTER (WHERE c = 4) AS c4 FROM t2; SELECT count(*) FILTER (WHERE b = 2) AS b2, count(*) FILTER (WHERE c = 4) AS c4 FROM t2;
b2 | c4 b2 | c4
@ -202,7 +202,7 @@ SELECT citus.mitmproxy('conn.onQuery(query="DELETE FROM").kill()');
-- issue a multi shard delete -- issue a multi shard delete
DELETE FROM t2 WHERE b = 2; DELETE FROM t2 WHERE b = 2;
ERROR: connection to the remote node localhost:xxxxx failed with the following error: connection not open ERROR: connection to the remote node postgres@localhost:xxxxx failed with the following error: connection not open
-- verify nothing is deleted -- verify nothing is deleted
SELECT count(*) FROM t2; SELECT count(*) FROM t2;
count count
@ -218,7 +218,7 @@ SELECT citus.mitmproxy('conn.onQuery(query="DELETE FROM multi_shard.t2_201005").
(1 row) (1 row)
DELETE FROM t2 WHERE b = 2; DELETE FROM t2 WHERE b = 2;
ERROR: connection to the remote node localhost:xxxxx failed with the following error: connection not open ERROR: connection to the remote node postgres@localhost:xxxxx failed with the following error: connection not open
-- verify nothing is deleted -- verify nothing is deleted
SELECT count(*) FROM t2; SELECT count(*) FROM t2;
count count
@ -278,7 +278,7 @@ SELECT citus.mitmproxy('conn.onQuery(query="^UPDATE").kill()');
-- issue a multi shard update -- issue a multi shard update
UPDATE t2 SET c = 4 WHERE b = 2; UPDATE t2 SET c = 4 WHERE b = 2;
ERROR: connection to the remote node localhost:xxxxx failed with the following error: connection not open ERROR: connection to the remote node postgres@localhost:xxxxx failed with the following error: connection not open
-- verify nothing is updated -- verify nothing is updated
SELECT count(*) FILTER (WHERE b = 2) AS b2, count(*) FILTER (WHERE c = 4) AS c4 FROM t2; SELECT count(*) FILTER (WHERE b = 2) AS b2, count(*) FILTER (WHERE c = 4) AS c4 FROM t2;
b2 | c4 b2 | c4
@ -294,7 +294,7 @@ SELECT citus.mitmproxy('conn.onQuery(query="UPDATE multi_shard.t2_201005").kill(
(1 row) (1 row)
UPDATE t2 SET c = 4 WHERE b = 2; UPDATE t2 SET c = 4 WHERE b = 2;
ERROR: connection to the remote node localhost:xxxxx failed with the following error: connection not open ERROR: connection to the remote node postgres@localhost:xxxxx failed with the following error: connection not open
-- verify nothing is updated -- verify nothing is updated
SELECT count(*) FILTER (WHERE b = 2) AS b2, count(*) FILTER (WHERE c = 4) AS c4 FROM t2; SELECT count(*) FILTER (WHERE b = 2) AS b2, count(*) FILTER (WHERE c = 4) AS c4 FROM t2;
b2 | c4 b2 | c4
@ -364,7 +364,7 @@ SELECT citus.mitmproxy('conn.onQuery(query="DELETE FROM").kill()');
(1 row) (1 row)
DELETE FROM r1 WHERE a = 2; DELETE FROM r1 WHERE a = 2;
ERROR: connection to the remote node localhost:xxxxx failed with the following error: connection not open ERROR: connection to the remote node postgres@localhost:xxxxx failed with the following error: connection not open
-- verify nothing is deleted -- verify nothing is deleted
SELECT count(*) FILTER (WHERE b = 2) AS b2 FROM t2; SELECT count(*) FILTER (WHERE b = 2) AS b2 FROM t2;
b2 b2
@ -379,7 +379,7 @@ SELECT citus.mitmproxy('conn.onQuery(query="DELETE FROM").kill()');
(1 row) (1 row)
DELETE FROM t2 WHERE b = 2; DELETE FROM t2 WHERE b = 2;
ERROR: connection to the remote node localhost:xxxxx failed with the following error: connection not open ERROR: connection to the remote node postgres@localhost:xxxxx failed with the following error: connection not open
-- verify nothing is deleted -- verify nothing is deleted
SELECT count(*) FILTER (WHERE b = 2) AS b2 FROM t2; SELECT count(*) FILTER (WHERE b = 2) AS b2 FROM t2;
b2 b2
@ -459,7 +459,7 @@ UPDATE t3 SET c = q.c FROM (
SELECT b, max(c) as c FROM t2 GROUP BY b) q SELECT b, max(c) as c FROM t2 GROUP BY b) q
WHERE t3.b = q.b WHERE t3.b = q.b
RETURNING *; RETURNING *;
ERROR: connection to the remote node localhost:xxxxx failed with the following error: connection not open ERROR: connection to the remote node postgres@localhost:xxxxx failed with the following error: connection not open
--- verify nothing is updated --- verify nothing is updated
SELECT citus.mitmproxy('conn.allow()'); SELECT citus.mitmproxy('conn.allow()');
mitmproxy mitmproxy
@ -515,7 +515,7 @@ SELECT citus.mitmproxy('conn.onQuery(query="UPDATE multi_shard.t3_201013").kill(
(1 row) (1 row)
UPDATE t3 SET b = 2 WHERE b = 1; UPDATE t3 SET b = 2 WHERE b = 1;
ERROR: connection to the remote node localhost:xxxxx failed with the following error: connection not open ERROR: connection to the remote node postgres@localhost:xxxxx failed with the following error: connection not open
-- verify nothing is updated -- verify nothing is updated
SELECT count(*) FILTER (WHERE b = 1) b1, count(*) FILTER (WHERE b = 2) AS b2 FROM t3; SELECT count(*) FILTER (WHERE b = 1) b1, count(*) FILTER (WHERE b = 2) AS b2 FROM t3;
b1 | b2 b1 | b2
@ -547,7 +547,7 @@ SELECT count(*) FILTER (WHERE b = 1) b1, count(*) FILTER (WHERE b = 2) AS b2 FRO
-- following will fail -- following will fail
UPDATE t3 SET b = 2 WHERE b = 1; UPDATE t3 SET b = 2 WHERE b = 1;
ERROR: connection to the remote node localhost:xxxxx failed with the following error: connection not open ERROR: connection to the remote node postgres@localhost:xxxxx failed with the following error: connection not open
END; END;
-- verify everything is rolled back -- verify everything is rolled back
SELECT count(*) FILTER (WHERE b = 1) b1, count(*) FILTER (WHERE b = 2) AS b2 FROM t2; SELECT count(*) FILTER (WHERE b = 1) b1, count(*) FILTER (WHERE b = 2) AS b2 FROM t2;
@ -563,7 +563,7 @@ SELECT count(*) FILTER (WHERE b = 1) b1, count(*) FILTER (WHERE b = 2) AS b2 FRO
(1 row) (1 row)
UPDATE t3 SET b = 1 WHERE b = 2 RETURNING *; UPDATE t3 SET b = 1 WHERE b = 2 RETURNING *;
ERROR: connection to the remote node localhost:xxxxx failed with the following error: connection not open ERROR: connection to the remote node postgres@localhost:xxxxx failed with the following error: connection not open
-- verify nothing is updated -- verify nothing is updated
SELECT count(*) FILTER (WHERE b = 1) b1, count(*) FILTER (WHERE b = 2) AS b2 FROM t3; SELECT count(*) FILTER (WHERE b = 1) b1, count(*) FILTER (WHERE b = 2) AS b2 FROM t3;
b1 | b2 b1 | b2
@ -578,7 +578,7 @@ SELECT count(*) FILTER (WHERE b = 1) b1, count(*) FILTER (WHERE b = 2) AS b2 FRO
(1 row) (1 row)
UPDATE t3 SET b = 2 WHERE b = 1; UPDATE t3 SET b = 2 WHERE b = 1;
ERROR: connection to the remote node localhost:xxxxx failed with the following error: connection not open ERROR: connection to the remote node postgres@localhost:xxxxx failed with the following error: connection not open
-- verify nothing is updated -- verify nothing is updated
SELECT count(*) FILTER (WHERE b = 1) b1, count(*) FILTER (WHERE b = 2) AS b2 FROM t3; SELECT count(*) FILTER (WHERE b = 1) b1, count(*) FILTER (WHERE b = 2) AS b2 FROM t3;
b1 | b2 b1 | b2
@ -610,7 +610,7 @@ SELECT count(*) FILTER (WHERE b = 1) b1, count(*) FILTER (WHERE b = 2) AS b2 FRO
-- following will fail -- following will fail
UPDATE t3 SET b = 2 WHERE b = 1; UPDATE t3 SET b = 2 WHERE b = 1;
ERROR: connection to the remote node localhost:xxxxx failed with the following error: connection not open ERROR: connection to the remote node postgres@localhost:xxxxx failed with the following error: connection not open
END; END;
-- verify everything is rolled back -- verify everything is rolled back
SELECT count(*) FILTER (WHERE b = 1) b1, count(*) FILTER (WHERE b = 2) AS b2 FROM t2; SELECT count(*) FILTER (WHERE b = 1) b1, count(*) FILTER (WHERE b = 2) AS b2 FROM t2;

View File

@ -155,7 +155,7 @@ SELECT citus.mitmproxy('conn.onQuery(query="UPDATE pg_dist_local_group SET group
(1 row) (1 row)
SELECT citus_activate_node('localhost', :worker_2_proxy_port); SELECT citus_activate_node('localhost', :worker_2_proxy_port);
ERROR: connection to the remote node localhost:xxxxx failed with the following error: connection not open ERROR: connection to the remote node postgres@localhost:xxxxx failed with the following error: connection not open
-- Failure to drop node metadata -- Failure to drop node metadata
SELECT citus.mitmproxy('conn.onQuery(query="DELETE FROM pg_dist_node").cancel(' || :pid || ')'); SELECT citus.mitmproxy('conn.onQuery(query="DELETE FROM pg_dist_node").cancel(' || :pid || ')');
mitmproxy mitmproxy
@ -172,7 +172,7 @@ SELECT citus.mitmproxy('conn.onQuery(query="DELETE FROM pg_dist_node").kill()');
(1 row) (1 row)
SELECT citus_activate_node('localhost', :worker_2_proxy_port); SELECT citus_activate_node('localhost', :worker_2_proxy_port);
ERROR: connection to the remote node localhost:xxxxx failed with the following error: connection not open ERROR: connection to the remote node postgres@localhost:xxxxx failed with the following error: connection not open
-- Failure to send node metadata -- Failure to send node metadata
SELECT citus.mitmproxy('conn.onQuery(query="INSERT INTO pg_dist_node").cancel(' || :pid || ')'); SELECT citus.mitmproxy('conn.onQuery(query="INSERT INTO pg_dist_node").cancel(' || :pid || ')');
mitmproxy mitmproxy
@ -189,7 +189,7 @@ SELECT citus.mitmproxy('conn.onQuery(query="INSERT INTO pg_dist_node").kill()');
(1 row) (1 row)
SELECT citus_activate_node('localhost', :worker_2_proxy_port); SELECT citus_activate_node('localhost', :worker_2_proxy_port);
ERROR: connection to the remote node localhost:xxxxx failed with the following error: connection not open ERROR: connection to the remote node postgres@localhost:xxxxx failed with the following error: connection not open
-- Failure to drop sequence dependency for all tables -- Failure to drop sequence dependency for all tables
SELECT citus.mitmproxy('conn.onQuery(query="SELECT pg_catalog.worker_drop_sequence_dependency.*FROM pg_dist_partition").cancel(' || :pid || ')'); SELECT citus.mitmproxy('conn.onQuery(query="SELECT pg_catalog.worker_drop_sequence_dependency.*FROM pg_dist_partition").cancel(' || :pid || ')');
mitmproxy mitmproxy
@ -206,7 +206,7 @@ SELECT citus.mitmproxy('conn.onQuery(query="SELECT pg_catalog.worker_drop_sequen
(1 row) (1 row)
SELECT citus_activate_node('localhost', :worker_2_proxy_port); SELECT citus_activate_node('localhost', :worker_2_proxy_port);
ERROR: connection to the remote node localhost:xxxxx failed with the following error: connection not open ERROR: connection to the remote node postgres@localhost:xxxxx failed with the following error: connection not open
-- Failure to drop shell table -- Failure to drop shell table
SELECT citus.mitmproxy('conn.onQuery(query="CALL pg_catalog.worker_drop_all_shell_tables").cancel(' || :pid || ')'); SELECT citus.mitmproxy('conn.onQuery(query="CALL pg_catalog.worker_drop_all_shell_tables").cancel(' || :pid || ')');
mitmproxy mitmproxy
@ -223,7 +223,7 @@ SELECT citus.mitmproxy('conn.onQuery(query="CALL pg_catalog.worker_drop_all_shel
(1 row) (1 row)
SELECT citus_activate_node('localhost', :worker_2_proxy_port); SELECT citus_activate_node('localhost', :worker_2_proxy_port);
ERROR: connection to the remote node localhost:xxxxx failed with the following error: connection not open ERROR: connection to the remote node postgres@localhost:xxxxx failed with the following error: connection not open
-- Failure to delete all pg_dist_partition metadata -- Failure to delete all pg_dist_partition metadata
SELECT citus.mitmproxy('conn.onQuery(query="DELETE FROM pg_dist_partition").cancel(' || :pid || ')'); SELECT citus.mitmproxy('conn.onQuery(query="DELETE FROM pg_dist_partition").cancel(' || :pid || ')');
mitmproxy mitmproxy
@ -240,7 +240,7 @@ SELECT citus.mitmproxy('conn.onQuery(query="DELETE FROM pg_dist_partition").kill
(1 row) (1 row)
SELECT citus_activate_node('localhost', :worker_2_proxy_port); SELECT citus_activate_node('localhost', :worker_2_proxy_port);
ERROR: connection to the remote node localhost:xxxxx failed with the following error: connection not open ERROR: connection to the remote node postgres@localhost:xxxxx failed with the following error: connection not open
-- Failure to delete all pg_dist_shard metadata -- Failure to delete all pg_dist_shard metadata
SELECT citus.mitmproxy('conn.onQuery(query="DELETE FROM pg_dist_shard").cancel(' || :pid || ')'); SELECT citus.mitmproxy('conn.onQuery(query="DELETE FROM pg_dist_shard").cancel(' || :pid || ')');
mitmproxy mitmproxy
@ -257,7 +257,7 @@ SELECT citus.mitmproxy('conn.onQuery(query="DELETE FROM pg_dist_shard").kill()')
(1 row) (1 row)
SELECT citus_activate_node('localhost', :worker_2_proxy_port); SELECT citus_activate_node('localhost', :worker_2_proxy_port);
ERROR: connection to the remote node localhost:xxxxx failed with the following error: connection not open ERROR: connection to the remote node postgres@localhost:xxxxx failed with the following error: connection not open
-- Failure to delete all pg_dist_placement metadata -- Failure to delete all pg_dist_placement metadata
SELECT citus.mitmproxy('conn.onQuery(query="DELETE FROM pg_dist_placement").cancel(' || :pid || ')'); SELECT citus.mitmproxy('conn.onQuery(query="DELETE FROM pg_dist_placement").cancel(' || :pid || ')');
mitmproxy mitmproxy
@ -274,7 +274,7 @@ SELECT citus.mitmproxy('conn.onQuery(query="DELETE FROM pg_dist_placement").kill
(1 row) (1 row)
SELECT citus_activate_node('localhost', :worker_2_proxy_port); SELECT citus_activate_node('localhost', :worker_2_proxy_port);
ERROR: connection to the remote node localhost:xxxxx failed with the following error: connection not open ERROR: connection to the remote node postgres@localhost:xxxxx failed with the following error: connection not open
-- Failure to delete all pg_dist_object metadata -- Failure to delete all pg_dist_object metadata
SELECT citus.mitmproxy('conn.onQuery(query="DELETE FROM pg_catalog.pg_dist_object").cancel(' || :pid || ')'); SELECT citus.mitmproxy('conn.onQuery(query="DELETE FROM pg_catalog.pg_dist_object").cancel(' || :pid || ')');
mitmproxy mitmproxy
@ -291,7 +291,7 @@ SELECT citus.mitmproxy('conn.onQuery(query="DELETE FROM pg_catalog.pg_dist_objec
(1 row) (1 row)
SELECT citus_activate_node('localhost', :worker_2_proxy_port); SELECT citus_activate_node('localhost', :worker_2_proxy_port);
ERROR: connection to the remote node localhost:xxxxx failed with the following error: connection not open ERROR: connection to the remote node postgres@localhost:xxxxx failed with the following error: connection not open
-- Failure to delete all pg_dist_colocation metadata -- Failure to delete all pg_dist_colocation metadata
SELECT citus.mitmproxy('conn.onQuery(query="DELETE FROM pg_catalog.pg_dist_colocation").cancel(' || :pid || ')'); SELECT citus.mitmproxy('conn.onQuery(query="DELETE FROM pg_catalog.pg_dist_colocation").cancel(' || :pid || ')');
mitmproxy mitmproxy
@ -308,7 +308,7 @@ SELECT citus.mitmproxy('conn.onQuery(query="DELETE FROM pg_catalog.pg_dist_coloc
(1 row) (1 row)
SELECT citus_activate_node('localhost', :worker_2_proxy_port); SELECT citus_activate_node('localhost', :worker_2_proxy_port);
ERROR: connection to the remote node localhost:xxxxx failed with the following error: connection not open ERROR: connection to the remote node postgres@localhost:xxxxx failed with the following error: connection not open
-- Failure to alter or create role -- Failure to alter or create role
SELECT citus.mitmproxy('conn.onQuery(query="SELECT worker_create_or_alter_role").cancel(' || :pid || ')'); SELECT citus.mitmproxy('conn.onQuery(query="SELECT worker_create_or_alter_role").cancel(' || :pid || ')');
mitmproxy mitmproxy
@ -325,7 +325,7 @@ SELECT citus.mitmproxy('conn.onQuery(query="SELECT worker_create_or_alter_role")
(1 row) (1 row)
SELECT citus_activate_node('localhost', :worker_2_proxy_port); SELECT citus_activate_node('localhost', :worker_2_proxy_port);
ERROR: connection to the remote node localhost:xxxxx failed with the following error: connection not open ERROR: connection to the remote node postgres@localhost:xxxxx failed with the following error: connection not open
-- Failure to set database owner -- Failure to set database owner
SELECT citus.mitmproxy('conn.onQuery(query="ALTER DATABASE.*OWNER TO").cancel(' || :pid || ')'); SELECT citus.mitmproxy('conn.onQuery(query="ALTER DATABASE.*OWNER TO").cancel(' || :pid || ')');
mitmproxy mitmproxy
@ -342,7 +342,7 @@ SELECT citus.mitmproxy('conn.onQuery(query="ALTER DATABASE.*OWNER TO").kill()');
(1 row) (1 row)
SELECT citus_activate_node('localhost', :worker_2_proxy_port); SELECT citus_activate_node('localhost', :worker_2_proxy_port);
ERROR: connection to the remote node localhost:xxxxx failed with the following error: connection not open ERROR: connection to the remote node postgres@localhost:xxxxx failed with the following error: connection not open
-- Failure to create schema -- Failure to create schema
SELECT citus.mitmproxy('conn.onQuery(query="CREATE SCHEMA IF NOT EXISTS mx_metadata_sync_multi_trans AUTHORIZATION").cancel(' || :pid || ')'); SELECT citus.mitmproxy('conn.onQuery(query="CREATE SCHEMA IF NOT EXISTS mx_metadata_sync_multi_trans AUTHORIZATION").cancel(' || :pid || ')');
mitmproxy mitmproxy
@ -359,7 +359,7 @@ SELECT citus.mitmproxy('conn.onQuery(query="CREATE SCHEMA IF NOT EXISTS mx_metad
(1 row) (1 row)
SELECT citus_activate_node('localhost', :worker_2_proxy_port); SELECT citus_activate_node('localhost', :worker_2_proxy_port);
ERROR: connection to the remote node localhost:xxxxx failed with the following error: connection not open ERROR: connection to the remote node postgres@localhost:xxxxx failed with the following error: connection not open
-- Failure to create collation -- Failure to create collation
SELECT citus.mitmproxy('conn.onQuery(query="SELECT worker_create_or_replace_object.*CREATE COLLATION mx_metadata_sync_multi_trans.german_phonebook").cancel(' || :pid || ')'); SELECT citus.mitmproxy('conn.onQuery(query="SELECT worker_create_or_replace_object.*CREATE COLLATION mx_metadata_sync_multi_trans.german_phonebook").cancel(' || :pid || ')');
mitmproxy mitmproxy
@ -376,7 +376,7 @@ SELECT citus.mitmproxy('conn.onQuery(query="SELECT worker_create_or_replace_obje
(1 row) (1 row)
SELECT citus_activate_node('localhost', :worker_2_proxy_port); SELECT citus_activate_node('localhost', :worker_2_proxy_port);
ERROR: connection to the remote node localhost:xxxxx failed with the following error: connection not open ERROR: connection to the remote node postgres@localhost:xxxxx failed with the following error: connection not open
-- Failure to create function -- Failure to create function
SELECT citus.mitmproxy('conn.onQuery(query="CREATE OR REPLACE FUNCTION mx_metadata_sync_multi_trans.one_as_result").cancel(' || :pid || ')'); SELECT citus.mitmproxy('conn.onQuery(query="CREATE OR REPLACE FUNCTION mx_metadata_sync_multi_trans.one_as_result").cancel(' || :pid || ')');
mitmproxy mitmproxy
@ -393,7 +393,7 @@ SELECT citus.mitmproxy('conn.onQuery(query="CREATE OR REPLACE FUNCTION mx_metada
(1 row) (1 row)
SELECT citus_activate_node('localhost', :worker_2_proxy_port); SELECT citus_activate_node('localhost', :worker_2_proxy_port);
ERROR: connection to the remote node localhost:xxxxx failed with the following error: connection not open ERROR: connection to the remote node postgres@localhost:xxxxx failed with the following error: connection not open
-- Failure to create text search dictionary -- Failure to create text search dictionary
SELECT citus.mitmproxy('conn.onQuery(query="SELECT worker_create_or_replace_object.*my_german_dict").cancel(' || :pid || ')'); SELECT citus.mitmproxy('conn.onQuery(query="SELECT worker_create_or_replace_object.*my_german_dict").cancel(' || :pid || ')');
mitmproxy mitmproxy
@ -410,7 +410,7 @@ SELECT citus.mitmproxy('conn.onQuery(query="SELECT worker_create_or_replace_obje
(1 row) (1 row)
SELECT citus_activate_node('localhost', :worker_2_proxy_port); SELECT citus_activate_node('localhost', :worker_2_proxy_port);
ERROR: connection to the remote node localhost:xxxxx failed with the following error: connection not open ERROR: connection to the remote node postgres@localhost:xxxxx failed with the following error: connection not open
-- Failure to create text search config -- Failure to create text search config
SELECT citus.mitmproxy('conn.onQuery(query="SELECT worker_create_or_replace_object.*my_ts_config").cancel(' || :pid || ')'); SELECT citus.mitmproxy('conn.onQuery(query="SELECT worker_create_or_replace_object.*my_ts_config").cancel(' || :pid || ')');
mitmproxy mitmproxy
@ -427,7 +427,7 @@ SELECT citus.mitmproxy('conn.onQuery(query="SELECT worker_create_or_replace_obje
(1 row) (1 row)
SELECT citus_activate_node('localhost', :worker_2_proxy_port); SELECT citus_activate_node('localhost', :worker_2_proxy_port);
ERROR: connection to the remote node localhost:xxxxx failed with the following error: connection not open ERROR: connection to the remote node postgres@localhost:xxxxx failed with the following error: connection not open
-- Failure to create type -- Failure to create type
SELECT citus.mitmproxy('conn.onQuery(query="SELECT worker_create_or_replace_object.*pair_type").cancel(' || :pid || ')'); SELECT citus.mitmproxy('conn.onQuery(query="SELECT worker_create_or_replace_object.*pair_type").cancel(' || :pid || ')');
mitmproxy mitmproxy
@ -444,7 +444,7 @@ SELECT citus.mitmproxy('conn.onQuery(query="SELECT worker_create_or_replace_obje
(1 row) (1 row)
SELECT citus_activate_node('localhost', :worker_2_proxy_port); SELECT citus_activate_node('localhost', :worker_2_proxy_port);
ERROR: connection to the remote node localhost:xxxxx failed with the following error: connection not open ERROR: connection to the remote node postgres@localhost:xxxxx failed with the following error: connection not open
-- Failure to create publication -- Failure to create publication
SELECT citus.mitmproxy('conn.onQuery(query="CREATE PUBLICATION.*pub_all").cancel(' || :pid || ')'); SELECT citus.mitmproxy('conn.onQuery(query="CREATE PUBLICATION.*pub_all").cancel(' || :pid || ')');
mitmproxy mitmproxy
@ -461,7 +461,7 @@ SELECT citus.mitmproxy('conn.onQuery(query="CREATE PUBLICATION.*pub_all").kill()
(1 row) (1 row)
SELECT citus_activate_node('localhost', :worker_2_proxy_port); SELECT citus_activate_node('localhost', :worker_2_proxy_port);
ERROR: connection to the remote node localhost:xxxxx failed with the following error: connection not open ERROR: connection to the remote node postgres@localhost:xxxxx failed with the following error: connection not open
-- Failure to create sequence -- Failure to create sequence
SELECT citus.mitmproxy('conn.onQuery(query="SELECT worker_apply_sequence_command").cancel(' || :pid || ')'); SELECT citus.mitmproxy('conn.onQuery(query="SELECT worker_apply_sequence_command").cancel(' || :pid || ')');
mitmproxy mitmproxy
@ -478,7 +478,7 @@ SELECT citus.mitmproxy('conn.onQuery(query="SELECT worker_apply_sequence_command
(1 row) (1 row)
SELECT citus_activate_node('localhost', :worker_2_proxy_port); SELECT citus_activate_node('localhost', :worker_2_proxy_port);
ERROR: connection to the remote node localhost:xxxxx failed with the following error: connection not open ERROR: connection to the remote node postgres@localhost:xxxxx failed with the following error: connection not open
-- Failure to drop sequence dependency for distributed table -- Failure to drop sequence dependency for distributed table
SELECT citus.mitmproxy('conn.onQuery(query="SELECT pg_catalog.worker_drop_sequence_dependency.*mx_metadata_sync_multi_trans.dist1").cancel(' || :pid || ')'); SELECT citus.mitmproxy('conn.onQuery(query="SELECT pg_catalog.worker_drop_sequence_dependency.*mx_metadata_sync_multi_trans.dist1").cancel(' || :pid || ')');
mitmproxy mitmproxy
@ -495,7 +495,7 @@ SELECT citus.mitmproxy('conn.onQuery(query="SELECT pg_catalog.worker_drop_sequen
(1 row) (1 row)
SELECT citus_activate_node('localhost', :worker_2_proxy_port); SELECT citus_activate_node('localhost', :worker_2_proxy_port);
ERROR: connection to the remote node localhost:xxxxx failed with the following error: connection not open ERROR: connection to the remote node postgres@localhost:xxxxx failed with the following error: connection not open
-- Failure to drop distributed table if exists -- Failure to drop distributed table if exists
SELECT citus.mitmproxy('conn.onQuery(query="DROP TABLE IF EXISTS mx_metadata_sync_multi_trans.dist1").cancel(' || :pid || ')'); SELECT citus.mitmproxy('conn.onQuery(query="DROP TABLE IF EXISTS mx_metadata_sync_multi_trans.dist1").cancel(' || :pid || ')');
mitmproxy mitmproxy
@ -512,7 +512,7 @@ SELECT citus.mitmproxy('conn.onQuery(query="DROP TABLE IF EXISTS mx_metadata_syn
(1 row) (1 row)
SELECT citus_activate_node('localhost', :worker_2_proxy_port); SELECT citus_activate_node('localhost', :worker_2_proxy_port);
ERROR: connection to the remote node localhost:xxxxx failed with the following error: connection not open ERROR: connection to the remote node postgres@localhost:xxxxx failed with the following error: connection not open
-- Failure to create distributed table -- Failure to create distributed table
SELECT citus.mitmproxy('conn.onQuery(query="CREATE TABLE mx_metadata_sync_multi_trans.dist1").cancel(' || :pid || ')'); SELECT citus.mitmproxy('conn.onQuery(query="CREATE TABLE mx_metadata_sync_multi_trans.dist1").cancel(' || :pid || ')');
mitmproxy mitmproxy
@ -529,7 +529,7 @@ SELECT citus.mitmproxy('conn.onQuery(query="CREATE TABLE mx_metadata_sync_multi_
(1 row) (1 row)
SELECT citus_activate_node('localhost', :worker_2_proxy_port); SELECT citus_activate_node('localhost', :worker_2_proxy_port);
ERROR: connection to the remote node localhost:xxxxx failed with the following error: connection not open ERROR: connection to the remote node postgres@localhost:xxxxx failed with the following error: connection not open
-- Failure to record sequence dependency for table -- Failure to record sequence dependency for table
SELECT citus.mitmproxy('conn.onQuery(query="SELECT pg_catalog.worker_record_sequence_dependency").cancel(' || :pid || ')'); SELECT citus.mitmproxy('conn.onQuery(query="SELECT pg_catalog.worker_record_sequence_dependency").cancel(' || :pid || ')');
mitmproxy mitmproxy
@ -546,7 +546,7 @@ SELECT citus.mitmproxy('conn.onQuery(query="SELECT pg_catalog.worker_record_sequ
(1 row) (1 row)
SELECT citus_activate_node('localhost', :worker_2_proxy_port); SELECT citus_activate_node('localhost', :worker_2_proxy_port);
ERROR: connection to the remote node localhost:xxxxx failed with the following error: connection not open ERROR: connection to the remote node postgres@localhost:xxxxx failed with the following error: connection not open
-- Failure to create index for table -- Failure to create index for table
SELECT citus.mitmproxy('conn.onQuery(query="CREATE INDEX dist1_search_phone_idx ON mx_metadata_sync_multi_trans.dist1 USING gin").cancel(' || :pid || ')'); SELECT citus.mitmproxy('conn.onQuery(query="CREATE INDEX dist1_search_phone_idx ON mx_metadata_sync_multi_trans.dist1 USING gin").cancel(' || :pid || ')');
mitmproxy mitmproxy
@ -563,7 +563,7 @@ SELECT citus.mitmproxy('conn.onQuery(query="CREATE INDEX dist1_search_phone_idx
(1 row) (1 row)
SELECT citus_activate_node('localhost', :worker_2_proxy_port); SELECT citus_activate_node('localhost', :worker_2_proxy_port);
ERROR: connection to the remote node localhost:xxxxx failed with the following error: connection not open ERROR: connection to the remote node postgres@localhost:xxxxx failed with the following error: connection not open
-- Failure to create reference table -- Failure to create reference table
SELECT citus.mitmproxy('conn.onQuery(query="CREATE TABLE mx_metadata_sync_multi_trans.ref").cancel(' || :pid || ')'); SELECT citus.mitmproxy('conn.onQuery(query="CREATE TABLE mx_metadata_sync_multi_trans.ref").cancel(' || :pid || ')');
mitmproxy mitmproxy
@ -580,7 +580,7 @@ SELECT citus.mitmproxy('conn.onQuery(query="CREATE TABLE mx_metadata_sync_multi_
(1 row) (1 row)
SELECT citus_activate_node('localhost', :worker_2_proxy_port); SELECT citus_activate_node('localhost', :worker_2_proxy_port);
ERROR: connection to the remote node localhost:xxxxx failed with the following error: connection not open ERROR: connection to the remote node postgres@localhost:xxxxx failed with the following error: connection not open
-- Failure to create local table -- Failure to create local table
SELECT citus.mitmproxy('conn.onQuery(query="CREATE TABLE mx_metadata_sync_multi_trans.loc1").cancel(' || :pid || ')'); SELECT citus.mitmproxy('conn.onQuery(query="CREATE TABLE mx_metadata_sync_multi_trans.loc1").cancel(' || :pid || ')');
mitmproxy mitmproxy
@ -597,7 +597,7 @@ SELECT citus.mitmproxy('conn.onQuery(query="CREATE TABLE mx_metadata_sync_multi_
(1 row) (1 row)
SELECT citus_activate_node('localhost', :worker_2_proxy_port); SELECT citus_activate_node('localhost', :worker_2_proxy_port);
ERROR: connection to the remote node localhost:xxxxx failed with the following error: connection not open ERROR: connection to the remote node postgres@localhost:xxxxx failed with the following error: connection not open
-- Failure to create distributed partitioned table -- Failure to create distributed partitioned table
SELECT citus.mitmproxy('conn.onQuery(query="CREATE TABLE mx_metadata_sync_multi_trans.orders").cancel(' || :pid || ')'); SELECT citus.mitmproxy('conn.onQuery(query="CREATE TABLE mx_metadata_sync_multi_trans.orders").cancel(' || :pid || ')');
mitmproxy mitmproxy
@ -614,7 +614,7 @@ SELECT citus.mitmproxy('conn.onQuery(query="CREATE TABLE mx_metadata_sync_multi_
(1 row) (1 row)
SELECT citus_activate_node('localhost', :worker_2_proxy_port); SELECT citus_activate_node('localhost', :worker_2_proxy_port);
ERROR: connection to the remote node localhost:xxxxx failed with the following error: connection not open ERROR: connection to the remote node postgres@localhost:xxxxx failed with the following error: connection not open
-- Failure to create distributed partition table -- Failure to create distributed partition table
SELECT citus.mitmproxy('conn.onQuery(query="CREATE TABLE mx_metadata_sync_multi_trans.orders_p2020_01_05").cancel(' || :pid || ')'); SELECT citus.mitmproxy('conn.onQuery(query="CREATE TABLE mx_metadata_sync_multi_trans.orders_p2020_01_05").cancel(' || :pid || ')');
mitmproxy mitmproxy
@ -631,7 +631,7 @@ SELECT citus.mitmproxy('conn.onQuery(query="CREATE TABLE mx_metadata_sync_multi_
(1 row) (1 row)
SELECT citus_activate_node('localhost', :worker_2_proxy_port); SELECT citus_activate_node('localhost', :worker_2_proxy_port);
ERROR: connection to the remote node localhost:xxxxx failed with the following error: connection not open ERROR: connection to the remote node postgres@localhost:xxxxx failed with the following error: connection not open
-- Failure to attach partition -- Failure to attach partition
SELECT citus.mitmproxy('conn.onQuery(query="ALTER TABLE mx_metadata_sync_multi_trans.orders ATTACH PARTITION mx_metadata_sync_multi_trans.orders_p2020_01_05").cancel(' || :pid || ')'); SELECT citus.mitmproxy('conn.onQuery(query="ALTER TABLE mx_metadata_sync_multi_trans.orders ATTACH PARTITION mx_metadata_sync_multi_trans.orders_p2020_01_05").cancel(' || :pid || ')');
mitmproxy mitmproxy
@ -648,7 +648,7 @@ SELECT citus.mitmproxy('conn.onQuery(query="ALTER TABLE mx_metadata_sync_multi_t
(1 row) (1 row)
SELECT citus_activate_node('localhost', :worker_2_proxy_port); SELECT citus_activate_node('localhost', :worker_2_proxy_port);
ERROR: connection to the remote node localhost:xxxxx failed with the following error: connection not open ERROR: connection to the remote node postgres@localhost:xxxxx failed with the following error: connection not open
-- Failure to add partition metadata -- Failure to add partition metadata
SELECT citus.mitmproxy('conn.onQuery(query="SELECT citus_internal_add_partition_metadata").cancel(' || :pid || ')'); SELECT citus.mitmproxy('conn.onQuery(query="SELECT citus_internal_add_partition_metadata").cancel(' || :pid || ')');
mitmproxy mitmproxy
@ -665,7 +665,7 @@ SELECT citus.mitmproxy('conn.onQuery(query="SELECT citus_internal_add_partition_
(1 row) (1 row)
SELECT citus_activate_node('localhost', :worker_2_proxy_port); SELECT citus_activate_node('localhost', :worker_2_proxy_port);
ERROR: connection to the remote node localhost:xxxxx failed with the following error: connection not open ERROR: connection to the remote node postgres@localhost:xxxxx failed with the following error: connection not open
-- Failure to add shard metadata -- Failure to add shard metadata
SELECT citus.mitmproxy('conn.onQuery(query="SELECT citus_internal_add_shard_metadata").cancel(' || :pid || ')'); SELECT citus.mitmproxy('conn.onQuery(query="SELECT citus_internal_add_shard_metadata").cancel(' || :pid || ')');
mitmproxy mitmproxy
@ -682,7 +682,7 @@ SELECT citus.mitmproxy('conn.onQuery(query="SELECT citus_internal_add_shard_meta
(1 row) (1 row)
SELECT citus_activate_node('localhost', :worker_2_proxy_port); SELECT citus_activate_node('localhost', :worker_2_proxy_port);
ERROR: connection to the remote node localhost:xxxxx failed with the following error: connection not open ERROR: connection to the remote node postgres@localhost:xxxxx failed with the following error: connection not open
-- Failure to add placement metadata -- Failure to add placement metadata
SELECT citus.mitmproxy('conn.onQuery(query="SELECT citus_internal_add_placement_metadata").cancel(' || :pid || ')'); SELECT citus.mitmproxy('conn.onQuery(query="SELECT citus_internal_add_placement_metadata").cancel(' || :pid || ')');
mitmproxy mitmproxy
@ -699,7 +699,7 @@ SELECT citus.mitmproxy('conn.onQuery(query="SELECT citus_internal_add_placement_
(1 row) (1 row)
SELECT citus_activate_node('localhost', :worker_2_proxy_port); SELECT citus_activate_node('localhost', :worker_2_proxy_port);
ERROR: connection to the remote node localhost:xxxxx failed with the following error: connection not open ERROR: connection to the remote node postgres@localhost:xxxxx failed with the following error: connection not open
-- Failure to add colocation metadata -- Failure to add colocation metadata
SELECT citus.mitmproxy('conn.onQuery(query="SELECT pg_catalog.citus_internal_add_colocation_metadata").cancel(' || :pid || ')'); SELECT citus.mitmproxy('conn.onQuery(query="SELECT pg_catalog.citus_internal_add_colocation_metadata").cancel(' || :pid || ')');
mitmproxy mitmproxy
@ -716,7 +716,7 @@ SELECT citus.mitmproxy('conn.onQuery(query="SELECT pg_catalog.citus_internal_add
(1 row) (1 row)
SELECT citus_activate_node('localhost', :worker_2_proxy_port); SELECT citus_activate_node('localhost', :worker_2_proxy_port);
ERROR: connection to the remote node localhost:xxxxx failed with the following error: connection not open ERROR: connection to the remote node postgres@localhost:xxxxx failed with the following error: connection not open
-- Failure to add distributed object metadata -- Failure to add distributed object metadata
SELECT citus.mitmproxy('conn.onQuery(query="SELECT citus_internal_add_object_metadata").cancel(' || :pid || ')'); SELECT citus.mitmproxy('conn.onQuery(query="SELECT citus_internal_add_object_metadata").cancel(' || :pid || ')');
mitmproxy mitmproxy
@ -733,7 +733,7 @@ SELECT citus.mitmproxy('conn.onQuery(query="SELECT citus_internal_add_object_met
(1 row) (1 row)
SELECT citus_activate_node('localhost', :worker_2_proxy_port); SELECT citus_activate_node('localhost', :worker_2_proxy_port);
ERROR: connection to the remote node localhost:xxxxx failed with the following error: connection not open ERROR: connection to the remote node postgres@localhost:xxxxx failed with the following error: connection not open
-- Failure to mark function as distributed -- Failure to mark function as distributed
SELECT citus.mitmproxy('conn.onQuery(query="WITH distributed_object_data.*one_as_result").cancel(' || :pid || ')'); SELECT citus.mitmproxy('conn.onQuery(query="WITH distributed_object_data.*one_as_result").cancel(' || :pid || ')');
mitmproxy mitmproxy
@ -750,7 +750,7 @@ SELECT citus.mitmproxy('conn.onQuery(query="WITH distributed_object_data.*one_as
(1 row) (1 row)
SELECT citus_activate_node('localhost', :worker_2_proxy_port); SELECT citus_activate_node('localhost', :worker_2_proxy_port);
ERROR: connection to the remote node localhost:xxxxx failed with the following error: connection not open ERROR: connection to the remote node postgres@localhost:xxxxx failed with the following error: connection not open
-- Failure to mark collation as distributed -- Failure to mark collation as distributed
SELECT citus.mitmproxy('conn.onQuery(query="WITH distributed_object_data.*german_phonebook").cancel(' || :pid || ')'); SELECT citus.mitmproxy('conn.onQuery(query="WITH distributed_object_data.*german_phonebook").cancel(' || :pid || ')');
mitmproxy mitmproxy
@ -767,7 +767,7 @@ SELECT citus.mitmproxy('conn.onQuery(query="WITH distributed_object_data.*german
(1 row) (1 row)
SELECT citus_activate_node('localhost', :worker_2_proxy_port); SELECT citus_activate_node('localhost', :worker_2_proxy_port);
ERROR: connection to the remote node localhost:xxxxx failed with the following error: connection not open ERROR: connection to the remote node postgres@localhost:xxxxx failed with the following error: connection not open
-- Failure to mark text search dictionary as distributed -- Failure to mark text search dictionary as distributed
SELECT citus.mitmproxy('conn.onQuery(query="WITH distributed_object_data.*my_german_dict").cancel(' || :pid || ')'); SELECT citus.mitmproxy('conn.onQuery(query="WITH distributed_object_data.*my_german_dict").cancel(' || :pid || ')');
mitmproxy mitmproxy
@ -784,7 +784,7 @@ SELECT citus.mitmproxy('conn.onQuery(query="WITH distributed_object_data.*my_ger
(1 row) (1 row)
SELECT citus_activate_node('localhost', :worker_2_proxy_port); SELECT citus_activate_node('localhost', :worker_2_proxy_port);
ERROR: connection to the remote node localhost:xxxxx failed with the following error: connection not open ERROR: connection to the remote node postgres@localhost:xxxxx failed with the following error: connection not open
-- Failure to mark text search configuration as distributed -- Failure to mark text search configuration as distributed
SELECT citus.mitmproxy('conn.onQuery(query="WITH distributed_object_data.*my_ts_config").cancel(' || :pid || ')'); SELECT citus.mitmproxy('conn.onQuery(query="WITH distributed_object_data.*my_ts_config").cancel(' || :pid || ')');
mitmproxy mitmproxy
@ -801,7 +801,7 @@ SELECT citus.mitmproxy('conn.onQuery(query="WITH distributed_object_data.*my_ts_
(1 row) (1 row)
SELECT citus_activate_node('localhost', :worker_2_proxy_port); SELECT citus_activate_node('localhost', :worker_2_proxy_port);
ERROR: connection to the remote node localhost:xxxxx failed with the following error: connection not open ERROR: connection to the remote node postgres@localhost:xxxxx failed with the following error: connection not open
-- Failure to mark type as distributed -- Failure to mark type as distributed
SELECT citus.mitmproxy('conn.onQuery(query="WITH distributed_object_data.*pair_type").cancel(' || :pid || ')'); SELECT citus.mitmproxy('conn.onQuery(query="WITH distributed_object_data.*pair_type").cancel(' || :pid || ')');
mitmproxy mitmproxy
@ -818,7 +818,7 @@ SELECT citus.mitmproxy('conn.onQuery(query="WITH distributed_object_data.*pair_t
(1 row) (1 row)
SELECT citus_activate_node('localhost', :worker_2_proxy_port); SELECT citus_activate_node('localhost', :worker_2_proxy_port);
ERROR: connection to the remote node localhost:xxxxx failed with the following error: connection not open ERROR: connection to the remote node postgres@localhost:xxxxx failed with the following error: connection not open
-- Failure to mark sequence as distributed -- Failure to mark sequence as distributed
SELECT citus.mitmproxy('conn.onQuery(query="WITH distributed_object_data.*seq_owned").cancel(' || :pid || ')'); SELECT citus.mitmproxy('conn.onQuery(query="WITH distributed_object_data.*seq_owned").cancel(' || :pid || ')');
mitmproxy mitmproxy
@ -835,7 +835,7 @@ SELECT citus.mitmproxy('conn.onQuery(query="WITH distributed_object_data.*seq_ow
(1 row) (1 row)
SELECT citus_activate_node('localhost', :worker_2_proxy_port); SELECT citus_activate_node('localhost', :worker_2_proxy_port);
ERROR: connection to the remote node localhost:xxxxx failed with the following error: connection not open ERROR: connection to the remote node postgres@localhost:xxxxx failed with the following error: connection not open
-- Failure to mark publication as distributed -- Failure to mark publication as distributed
SELECT citus.mitmproxy('conn.onQuery(query="WITH distributed_object_data.*pub_all").cancel(' || :pid || ')'); SELECT citus.mitmproxy('conn.onQuery(query="WITH distributed_object_data.*pub_all").cancel(' || :pid || ')');
mitmproxy mitmproxy
@ -852,7 +852,7 @@ SELECT citus.mitmproxy('conn.onQuery(query="WITH distributed_object_data.*pub_al
(1 row) (1 row)
SELECT citus_activate_node('localhost', :worker_2_proxy_port); SELECT citus_activate_node('localhost', :worker_2_proxy_port);
ERROR: connection to the remote node localhost:xxxxx failed with the following error: connection not open ERROR: connection to the remote node postgres@localhost:xxxxx failed with the following error: connection not open
-- Failure to set isactive to true -- Failure to set isactive to true
SELECT citus.mitmproxy('conn.onQuery(query="UPDATE pg_dist_node SET isactive = TRUE").cancel(' || :pid || ')'); SELECT citus.mitmproxy('conn.onQuery(query="UPDATE pg_dist_node SET isactive = TRUE").cancel(' || :pid || ')');
mitmproxy mitmproxy

View File

@ -43,9 +43,9 @@ SELECT * FROM shards_in_workers;
-- Failure on creating the subscription -- Failure on creating the subscription
-- Failing exactly on CREATE SUBSCRIPTION is causing flaky test where we fail with either: -- Failing exactly on CREATE SUBSCRIPTION is causing flaky test where we fail with either:
-- 1) ERROR: connection to the remote node localhost:xxxxx failed with the following error: ERROR: subscription "citus_shard_move_subscription_xxxxxxx" does not exist -- 1) ERROR: connection to the remote node postgres@localhost:xxxxx failed with the following error: ERROR: subscription "citus_shard_move_subscription_xxxxxxx" does not exist
-- another command is already in progress -- another command is already in progress
-- 2) ERROR: connection to the remote node localhost:xxxxx failed with the following error: another command is already in progress -- 2) ERROR: connection to the remote node postgres@localhost:xxxxx failed with the following error: another command is already in progress
-- Instead fail on the next step (ALTER SUBSCRIPTION) instead which is also required logically as part of uber CREATE SUBSCRIPTION operation. -- Instead fail on the next step (ALTER SUBSCRIPTION) instead which is also required logically as part of uber CREATE SUBSCRIPTION operation.
SELECT citus.mitmproxy('conn.onQuery(query="ALTER SUBSCRIPTION").kill()'); SELECT citus.mitmproxy('conn.onQuery(query="ALTER SUBSCRIPTION").kill()');
mitmproxy mitmproxy

View File

@ -407,7 +407,7 @@ SELECT citus.mitmproxy('conn.matches(b"CREATE INDEX").killall()');
(1 row) (1 row)
SELECT master_move_shard_placement(101, 'localhost', :worker_1_port, 'localhost', :worker_2_proxy_port); SELECT master_move_shard_placement(101, 'localhost', :worker_1_port, 'localhost', :worker_2_proxy_port);
ERROR: connection to the remote node localhost:xxxxx failed with the following error: connection not open ERROR: connection to the remote node postgres@localhost:xxxxx failed with the following error: connection not open
-- cleanup leftovers -- cleanup leftovers
SELECT citus.mitmproxy('conn.allow()'); SELECT citus.mitmproxy('conn.allow()');
mitmproxy mitmproxy
@ -442,7 +442,7 @@ SELECT citus.mitmproxy('conn.matches(b"CREATE INDEX").killall()');
(1 row) (1 row)
SELECT master_move_shard_placement(101, 'localhost', :worker_1_port, 'localhost', :worker_2_proxy_port); SELECT master_move_shard_placement(101, 'localhost', :worker_1_port, 'localhost', :worker_2_proxy_port);
ERROR: connection to the remote node localhost:xxxxx failed with the following error: connection not open ERROR: connection to the remote node postgres@localhost:xxxxx failed with the following error: connection not open
-- failure on parallel create index -- failure on parallel create index
ALTER SYSTEM RESET citus.max_adaptive_executor_pool_size; ALTER SYSTEM RESET citus.max_adaptive_executor_pool_size;
SELECT pg_reload_conf(); SELECT pg_reload_conf();
@ -458,7 +458,7 @@ SELECT citus.mitmproxy('conn.matches(b"CREATE INDEX").killall()');
(1 row) (1 row)
SELECT master_move_shard_placement(101, 'localhost', :worker_1_port, 'localhost', :worker_2_proxy_port); SELECT master_move_shard_placement(101, 'localhost', :worker_1_port, 'localhost', :worker_2_proxy_port);
ERROR: connection to the remote node localhost:xxxxx failed with the following error: connection not open ERROR: connection to the remote node postgres@localhost:xxxxx failed with the following error: connection not open
-- Verify that the shard is not moved and the number of rows are still 100k -- Verify that the shard is not moved and the number of rows are still 100k
SELECT citus.mitmproxy('conn.allow()'); SELECT citus.mitmproxy('conn.allow()');
mitmproxy mitmproxy

View File

@ -33,7 +33,7 @@ SELECT citus.mitmproxy('conn.onQuery(query="INSERT").kill()');
(1 row) (1 row)
INSERT INTO ref_table VALUES (5, 6); INSERT INTO ref_table VALUES (5, 6);
ERROR: connection to the remote node localhost:xxxxx failed with the following error: connection not open ERROR: connection to the remote node postgres@localhost:xxxxx failed with the following error: connection not open
SELECT COUNT(*) FROM ref_table WHERE key=5; SELECT COUNT(*) FROM ref_table WHERE key=5;
count count
--------------------------------------------------------------------- ---------------------------------------------------------------------
@ -48,7 +48,7 @@ SELECT citus.mitmproxy('conn.onQuery(query="UPDATE").kill()');
(1 row) (1 row)
UPDATE ref_table SET key=7 RETURNING value; UPDATE ref_table SET key=7 RETURNING value;
ERROR: connection to the remote node localhost:xxxxx failed with the following error: connection not open ERROR: connection to the remote node postgres@localhost:xxxxx failed with the following error: connection not open
SELECT COUNT(*) FROM ref_table WHERE key=7; SELECT COUNT(*) FROM ref_table WHERE key=7;
count count
--------------------------------------------------------------------- ---------------------------------------------------------------------
@ -65,7 +65,7 @@ SELECT citus.mitmproxy('conn.onQuery(query="UPDATE").kill()');
BEGIN; BEGIN;
DELETE FROM ref_table WHERE key=5; DELETE FROM ref_table WHERE key=5;
UPDATE ref_table SET key=value; UPDATE ref_table SET key=value;
ERROR: connection to the remote node localhost:xxxxx failed with the following error: connection not open ERROR: connection to the remote node postgres@localhost:xxxxx failed with the following error: connection not open
COMMIT; COMMIT;
SELECT COUNT(*) FROM ref_table WHERE key=value; SELECT COUNT(*) FROM ref_table WHERE key=value;
count count

View File

@ -28,7 +28,7 @@ SELECT citus.mitmproxy('conn.onQuery(query="INSERT").kill()');
(1 row) (1 row)
INSERT INTO partitioned_table VALUES (0, 0); INSERT INTO partitioned_table VALUES (0, 0);
ERROR: connection to the remote node localhost:xxxxx failed with the following error: connection not open ERROR: connection to the remote node postgres@localhost:xxxxx failed with the following error: connection not open
-- use both placements -- use both placements
SET citus.task_assignment_policy TO "round-robin"; SET citus.task_assignment_policy TO "round-robin";
-- the results should be the same -- the results should be the same

View File

@ -312,7 +312,7 @@ SELECT * FROM ref;
ROLLBACK TO SAVEPOINT start; ROLLBACK TO SAVEPOINT start;
SELECT * FROM ref; SELECT * FROM ref;
ERROR: connection to the remote node localhost:xxxxx failed with the following error: connection not open ERROR: connection to the remote node postgres@localhost:xxxxx failed with the following error: connection not open
END; END;
-- clean up -- clean up
RESET client_min_messages; RESET client_min_messages;

View File

@ -27,7 +27,7 @@ SELECT citus.mitmproxy('conn.onQuery(query="INSERT").kill()');
(1 row) (1 row)
INSERT INTO mod_test VALUES (2, 6); INSERT INTO mod_test VALUES (2, 6);
ERROR: connection to the remote node localhost:xxxxx failed with the following error: connection not open ERROR: connection to the remote node postgres@localhost:xxxxx failed with the following error: connection not open
SELECT COUNT(*) FROM mod_test WHERE key=2; SELECT COUNT(*) FROM mod_test WHERE key=2;
count count
--------------------------------------------------------------------- ---------------------------------------------------------------------
@ -59,7 +59,7 @@ SELECT citus.mitmproxy('conn.onQuery(query="UPDATE").kill()');
(1 row) (1 row)
UPDATE mod_test SET value='ok' WHERE key=2 RETURNING key; UPDATE mod_test SET value='ok' WHERE key=2 RETURNING key;
ERROR: connection to the remote node localhost:xxxxx failed with the following error: connection not open ERROR: connection to the remote node postgres@localhost:xxxxx failed with the following error: connection not open
SELECT COUNT(*) FROM mod_test WHERE value='ok'; SELECT COUNT(*) FROM mod_test WHERE value='ok';
count count
--------------------------------------------------------------------- ---------------------------------------------------------------------
@ -89,7 +89,7 @@ INSERT INTO mod_test VALUES (2, 6);
INSERT INTO mod_test VALUES (2, 7); INSERT INTO mod_test VALUES (2, 7);
DELETE FROM mod_test WHERE key=2 AND value = '7'; DELETE FROM mod_test WHERE key=2 AND value = '7';
UPDATE mod_test SET value='ok' WHERE key=2; UPDATE mod_test SET value='ok' WHERE key=2;
ERROR: connection to the remote node localhost:xxxxx failed with the following error: connection not open ERROR: connection to the remote node postgres@localhost:xxxxx failed with the following error: connection not open
COMMIT; COMMIT;
SELECT COUNT(*) FROM mod_test WHERE key=2; SELECT COUNT(*) FROM mod_test WHERE key=2;
count count

View File

@ -30,14 +30,14 @@ SELECT citus.mitmproxy('conn.onQuery(query="SELECT.*select_test").kill()');
(1 row) (1 row)
SELECT * FROM select_test WHERE key = 3; SELECT * FROM select_test WHERE key = 3;
WARNING: connection to the remote node localhost:xxxxx failed with the following error: connection not open WARNING: connection to the remote node postgres@localhost:xxxxx failed with the following error: connection not open
key | value key | value
--------------------------------------------------------------------- ---------------------------------------------------------------------
3 | test data 3 | test data
(1 row) (1 row)
SELECT * FROM select_test WHERE key = 3; SELECT * FROM select_test WHERE key = 3;
WARNING: connection to the remote node localhost:xxxxx failed with the following error: connection not open WARNING: connection to the remote node postgres@localhost:xxxxx failed with the following error: connection not open
key | value key | value
--------------------------------------------------------------------- ---------------------------------------------------------------------
3 | test data 3 | test data
@ -54,7 +54,7 @@ SELECT citus.mitmproxy('conn.onQuery(query="SELECT.*select_test").kill()');
BEGIN; BEGIN;
INSERT INTO select_test VALUES (3, 'more data'); INSERT INTO select_test VALUES (3, 'more data');
SELECT * FROM select_test WHERE key = 3; SELECT * FROM select_test WHERE key = 3;
ERROR: connection to the remote node localhost:xxxxx failed with the following error: connection not open ERROR: connection to the remote node postgres@localhost:xxxxx failed with the following error: connection not open
COMMIT; COMMIT;
SELECT citus.mitmproxy('conn.allow()'); SELECT citus.mitmproxy('conn.allow()');
mitmproxy mitmproxy
@ -142,7 +142,7 @@ SELECT * FROM select_test WHERE key = 3;
INSERT INTO select_test VALUES (3, 'even more data'); INSERT INTO select_test VALUES (3, 'even more data');
SELECT * FROM select_test WHERE key = 3; SELECT * FROM select_test WHERE key = 3;
ERROR: connection to the remote node localhost:xxxxx failed with the following error: connection not open ERROR: connection to the remote node postgres@localhost:xxxxx failed with the following error: connection not open
COMMIT; COMMIT;
SELECT citus.mitmproxy('conn.onQuery(query="SELECT.*pg_prepared_xacts").after(2).kill()'); SELECT citus.mitmproxy('conn.onQuery(query="SELECT.*pg_prepared_xacts").after(2).kill()');
mitmproxy mitmproxy
@ -186,7 +186,7 @@ SELECT * FROM select_test WHERE key = 1;
(1 row) (1 row)
SELECT * FROM select_test WHERE key = 1; SELECT * FROM select_test WHERE key = 1;
ERROR: connection to the remote node localhost:xxxxx failed with the following error: connection not open ERROR: connection to the remote node postgres@localhost:xxxxx failed with the following error: connection not open
-- now the same test with query cancellation -- now the same test with query cancellation
SELECT citus.mitmproxy('conn.onQuery(query="SELECT.*select_test").after(1).cancel(' || pg_backend_pid() || ')'); SELECT citus.mitmproxy('conn.onQuery(query="SELECT.*select_test").after(1).cancel(' || pg_backend_pid() || ')');
mitmproxy mitmproxy

View File

@ -627,10 +627,10 @@ WARNING: connection not open
CONTEXT: while executing command on localhost:xxxxx CONTEXT: while executing command on localhost:xxxxx
WARNING: connection not open WARNING: connection not open
CONTEXT: while executing command on localhost:xxxxx CONTEXT: while executing command on localhost:xxxxx
WARNING: connection to the remote node localhost:xxxxx failed with the following error: connection not open WARNING: connection to the remote node postgres@localhost:xxxxx failed with the following error: connection not open
WARNING: connection to the remote node localhost:xxxxx failed with the following error: connection not open WARNING: connection to the remote node postgres@localhost:xxxxx failed with the following error: connection not open
WARNING: connection to the remote node localhost:xxxxx failed with the following error: connection not open WARNING: connection to the remote node postgres@localhost:xxxxx failed with the following error: connection not open
WARNING: connection to the remote node localhost:xxxxx failed with the following error: connection not open WARNING: connection to the remote node postgres@localhost:xxxxx failed with the following error: connection not open
ERROR: connection not open ERROR: connection not open
CONTEXT: while executing command on localhost:xxxxx CONTEXT: while executing command on localhost:xxxxx
SELECT operation_id, object_type, object_name, node_group_id, policy_type SELECT operation_id, object_type, object_name, node_group_id, policy_type

View File

@ -76,7 +76,7 @@ SELECT citus.mitmproxy('conn.onQuery(query="worker_split_copy\(302").kill()');
(1 row) (1 row)
SELECT isolate_tenant_to_new_shard('table_1', 5, 'CASCADE', shard_transfer_mode => 'block_writes'); SELECT isolate_tenant_to_new_shard('table_1', 5, 'CASCADE', shard_transfer_mode => 'block_writes');
ERROR: connection to the remote node localhost:xxxxx failed with the following error: connection not open ERROR: connection to the remote node postgres@localhost:xxxxx failed with the following error: connection not open
-- cancellation on colocated table population -- cancellation on colocated table population
SELECT citus.mitmproxy('conn.onQuery(query="worker_split_copy\(302").cancel(' || :pid || ')'); SELECT citus.mitmproxy('conn.onQuery(query="worker_split_copy\(302").cancel(' || :pid || ')');
mitmproxy mitmproxy
@ -94,7 +94,7 @@ SELECT citus.mitmproxy('conn.onQuery(query="ALTER TABLE tenant_isolation.table_2
(1 row) (1 row)
SELECT isolate_tenant_to_new_shard('table_1', 5, 'CASCADE', shard_transfer_mode => 'block_writes'); SELECT isolate_tenant_to_new_shard('table_1', 5, 'CASCADE', shard_transfer_mode => 'block_writes');
ERROR: connection to the remote node localhost:xxxxx failed with the following error: connection not open ERROR: connection to the remote node postgres@localhost:xxxxx failed with the following error: connection not open
-- cancellation on colocated table constraints -- cancellation on colocated table constraints
SELECT citus.mitmproxy('conn.onQuery(query="ALTER TABLE tenant_isolation.table_2 ADD CONSTRAINT").after(2).cancel(' || :pid || ')'); SELECT citus.mitmproxy('conn.onQuery(query="ALTER TABLE tenant_isolation.table_2 ADD CONSTRAINT").after(2).cancel(' || :pid || ')');
mitmproxy mitmproxy
@ -131,7 +131,7 @@ SELECT citus.mitmproxy('conn.onQuery(query="worker_split_copy\(300").kill()');
(1 row) (1 row)
SELECT isolate_tenant_to_new_shard('table_1', 5, 'CASCADE', shard_transfer_mode => 'block_writes'); SELECT isolate_tenant_to_new_shard('table_1', 5, 'CASCADE', shard_transfer_mode => 'block_writes');
ERROR: connection to the remote node localhost:xxxxx failed with the following error: connection not open ERROR: connection to the remote node postgres@localhost:xxxxx failed with the following error: connection not open
-- cancellation on table population -- cancellation on table population
SELECT citus.mitmproxy('conn.onQuery(query="worker_split_copy\(300").cancel(' || :pid || ')'); SELECT citus.mitmproxy('conn.onQuery(query="worker_split_copy\(300").cancel(' || :pid || ')');
mitmproxy mitmproxy
@ -149,7 +149,7 @@ SELECT citus.mitmproxy('conn.onQuery(query="ALTER TABLE tenant_isolation.table_1
(1 row) (1 row)
SELECT isolate_tenant_to_new_shard('table_1', 5, 'CASCADE', shard_transfer_mode => 'block_writes'); SELECT isolate_tenant_to_new_shard('table_1', 5, 'CASCADE', shard_transfer_mode => 'block_writes');
ERROR: connection to the remote node localhost:xxxxx failed with the following error: connection not open ERROR: connection to the remote node postgres@localhost:xxxxx failed with the following error: connection not open
-- cancellation on table constraints -- cancellation on table constraints
SELECT citus.mitmproxy('conn.onQuery(query="ALTER TABLE tenant_isolation.table_1 ADD CONSTRAINT").after(2).cancel(' || :pid || ')'); SELECT citus.mitmproxy('conn.onQuery(query="ALTER TABLE tenant_isolation.table_1 ADD CONSTRAINT").after(2).cancel(' || :pid || ')');
mitmproxy mitmproxy

View File

@ -159,7 +159,7 @@ SELECT citus.mitmproxy('conn.onQuery(query="SET TRANSACTION SNAPSHOT").kill()');
(1 row) (1 row)
SELECT isolate_tenant_to_new_shard('table_1', 5, 'CASCADE', shard_transfer_mode := 'force_logical'); SELECT isolate_tenant_to_new_shard('table_1', 5, 'CASCADE', shard_transfer_mode := 'force_logical');
ERROR: connection to the remote node localhost:xxxxx failed with the following error: connection not open ERROR: connection to the remote node postgres@localhost:xxxxx failed with the following error: connection not open
-- cancellation on setting snapshot -- cancellation on setting snapshot
SELECT citus.mitmproxy('conn.onQuery(query="SET TRANSACTION SNAPSHOT").cancel(' || :pid || ')'); SELECT citus.mitmproxy('conn.onQuery(query="SET TRANSACTION SNAPSHOT").cancel(' || :pid || ')');
mitmproxy mitmproxy
@ -177,7 +177,7 @@ SELECT citus.mitmproxy('conn.onQuery(query="worker_split_copy\(300").kill()');
(1 row) (1 row)
SELECT isolate_tenant_to_new_shard('table_1', 5, 'CASCADE', shard_transfer_mode := 'force_logical'); SELECT isolate_tenant_to_new_shard('table_1', 5, 'CASCADE', shard_transfer_mode := 'force_logical');
ERROR: connection to the remote node localhost:xxxxx failed with the following error: connection not open ERROR: connection to the remote node postgres@localhost:xxxxx failed with the following error: connection not open
-- cancellation on table population -- cancellation on table population
SELECT citus.mitmproxy('conn.onQuery(query="worker_split_copy\(300").cancel(' || :pid || ')'); SELECT citus.mitmproxy('conn.onQuery(query="worker_split_copy\(300").cancel(' || :pid || ')');
mitmproxy mitmproxy
@ -195,7 +195,7 @@ SELECT citus.mitmproxy('conn.onQuery(query="worker_split_copy\(302").kill()');
(1 row) (1 row)
SELECT isolate_tenant_to_new_shard('table_1', 5, 'CASCADE', shard_transfer_mode := 'force_logical'); SELECT isolate_tenant_to_new_shard('table_1', 5, 'CASCADE', shard_transfer_mode := 'force_logical');
ERROR: connection to the remote node localhost:xxxxx failed with the following error: connection not open ERROR: connection to the remote node postgres@localhost:xxxxx failed with the following error: connection not open
-- cancellation on colocated table population -- cancellation on colocated table population
SELECT citus.mitmproxy('conn.onQuery(query="worker_split_copy\(302").cancel(' || :pid || ')'); SELECT citus.mitmproxy('conn.onQuery(query="worker_split_copy\(302").cancel(' || :pid || ')');
mitmproxy mitmproxy

View File

@ -43,7 +43,7 @@ SELECT citus.mitmproxy('conn.onAuthenticationOk().kill()');
(1 row) (1 row)
TRUNCATE test_table; TRUNCATE test_table;
ERROR: connection to the remote node localhost:xxxxx failed with the following error: connection not open ERROR: connection to the remote node postgres@localhost:xxxxx failed with the following error: connection not open
SELECT citus.mitmproxy('conn.allow()'); SELECT citus.mitmproxy('conn.allow()');
mitmproxy mitmproxy
--------------------------------------------------------------------- ---------------------------------------------------------------------
@ -152,7 +152,7 @@ SELECT citus.mitmproxy('conn.onQuery(query="TRUNCATE TABLE truncate_failure.test
(1 row) (1 row)
TRUNCATE test_table; TRUNCATE test_table;
ERROR: connection to the remote node localhost:xxxxx failed with the following error: connection not open ERROR: connection to the remote node postgres@localhost:xxxxx failed with the following error: connection not open
SELECT citus.mitmproxy('conn.allow()'); SELECT citus.mitmproxy('conn.allow()');
mitmproxy mitmproxy
--------------------------------------------------------------------- ---------------------------------------------------------------------
@ -414,7 +414,7 @@ SELECT citus.mitmproxy('conn.onQuery(query="^TRUNCATE TABLE").after(2).kill()');
(1 row) (1 row)
TRUNCATE reference_table CASCADE; TRUNCATE reference_table CASCADE;
ERROR: connection to the remote node localhost:xxxxx failed with the following error: connection not open ERROR: connection to the remote node postgres@localhost:xxxxx failed with the following error: connection not open
SELECT citus.mitmproxy('conn.allow()'); SELECT citus.mitmproxy('conn.allow()');
mitmproxy mitmproxy
--------------------------------------------------------------------- ---------------------------------------------------------------------
@ -553,7 +553,7 @@ SELECT citus.mitmproxy('conn.onAuthenticationOk().kill()');
(1 row) (1 row)
TRUNCATE test_table; TRUNCATE test_table;
ERROR: connection to the remote node localhost:xxxxx failed with the following error: connection not open ERROR: connection to the remote node postgres@localhost:xxxxx failed with the following error: connection not open
SELECT citus.mitmproxy('conn.allow()'); SELECT citus.mitmproxy('conn.allow()');
mitmproxy mitmproxy
--------------------------------------------------------------------- ---------------------------------------------------------------------
@ -662,7 +662,7 @@ SELECT citus.mitmproxy('conn.onQuery(query="^TRUNCATE TABLE truncate_failure.tes
(1 row) (1 row)
TRUNCATE test_table; TRUNCATE test_table;
ERROR: connection to the remote node localhost:xxxxx failed with the following error: connection not open ERROR: connection to the remote node postgres@localhost:xxxxx failed with the following error: connection not open
SELECT citus.mitmproxy('conn.allow()'); SELECT citus.mitmproxy('conn.allow()');
mitmproxy mitmproxy
--------------------------------------------------------------------- ---------------------------------------------------------------------
@ -922,7 +922,7 @@ SELECT citus.mitmproxy('conn.onAuthenticationOk().kill()');
(1 row) (1 row)
TRUNCATE test_table; TRUNCATE test_table;
ERROR: connection to the remote node localhost:xxxxx failed with the following error: connection not open ERROR: connection to the remote node postgres@localhost:xxxxx failed with the following error: connection not open
SELECT citus.mitmproxy('conn.allow()'); SELECT citus.mitmproxy('conn.allow()');
mitmproxy mitmproxy
--------------------------------------------------------------------- ---------------------------------------------------------------------
@ -1031,7 +1031,7 @@ SELECT citus.mitmproxy('conn.onQuery(query="TRUNCATE TABLE truncate_failure.test
(1 row) (1 row)
TRUNCATE test_table; TRUNCATE test_table;
ERROR: connection to the remote node localhost:xxxxx failed with the following error: connection not open ERROR: connection to the remote node postgres@localhost:xxxxx failed with the following error: connection not open
SELECT citus.mitmproxy('conn.allow()'); SELECT citus.mitmproxy('conn.allow()');
mitmproxy mitmproxy
--------------------------------------------------------------------- ---------------------------------------------------------------------

View File

@ -30,7 +30,7 @@ SELECT citus.mitmproxy('conn.onQuery(query="^VACUUM").kill()');
(1 row) (1 row)
VACUUM vacuum_test; VACUUM vacuum_test;
ERROR: connection to the remote node localhost:xxxxx failed with the following error: connection not open ERROR: connection to the remote node postgres@localhost:xxxxx failed with the following error: connection not open
SELECT citus.mitmproxy('conn.onQuery(query="^ANALYZE").kill()'); SELECT citus.mitmproxy('conn.onQuery(query="^ANALYZE").kill()');
mitmproxy mitmproxy
--------------------------------------------------------------------- ---------------------------------------------------------------------
@ -38,7 +38,7 @@ SELECT citus.mitmproxy('conn.onQuery(query="^ANALYZE").kill()');
(1 row) (1 row)
ANALYZE vacuum_test; ANALYZE vacuum_test;
ERROR: connection to the remote node localhost:xxxxx failed with the following error: connection not open ERROR: connection to the remote node postgres@localhost:xxxxx failed with the following error: connection not open
SET client_min_messages TO ERROR; SET client_min_messages TO ERROR;
SELECT citus.mitmproxy('conn.onQuery(query="^COMMIT").kill()'); SELECT citus.mitmproxy('conn.onQuery(query="^COMMIT").kill()');
mitmproxy mitmproxy
@ -113,7 +113,7 @@ SELECT citus.mitmproxy('conn.onQuery(query="^VACUUM.*other").kill()');
(1 row) (1 row)
VACUUM vacuum_test, other_vacuum_test; VACUUM vacuum_test, other_vacuum_test;
ERROR: connection to the remote node localhost:xxxxx failed with the following error: connection not open ERROR: connection to the remote node postgres@localhost:xxxxx failed with the following error: connection not open
SELECT citus.mitmproxy('conn.onQuery(query="^VACUUM.*other").cancel(' || pg_backend_pid() || ')'); SELECT citus.mitmproxy('conn.onQuery(query="^VACUUM.*other").cancel(' || pg_backend_pid() || ')');
mitmproxy mitmproxy
--------------------------------------------------------------------- ---------------------------------------------------------------------

View File

@ -250,7 +250,7 @@ count
step s1-commit-prepared: step s1-commit-prepared:
COMMIT prepared 'label'; COMMIT prepared 'label';
s2: WARNING: connection to the remote node non-existent:57637 failed with the following error: could not translate host name "non-existent" to address: <system specific error> s2: WARNING: connection to the remote node postgres@non-existent:57637 failed with the following error: could not translate host name "non-existent" to address: <system specific error>
step s2-execute-prepared: step s2-execute-prepared:
EXECUTE foo; EXECUTE foo;

View File

@ -3281,9 +3281,9 @@ SELECT pg_sleep(0.1); -- wait to make sure the config has changed before running
SET citus.enable_local_execution TO false; -- force a connection to the dummy placements SET citus.enable_local_execution TO false; -- force a connection to the dummy placements
-- run queries that use dummy placements for local execution -- run queries that use dummy placements for local execution
SELECT * FROM event_responses WHERE FALSE; SELECT * FROM event_responses WHERE FALSE;
ERROR: connection to the remote node foobar:57636 failed with the following error: could not translate host name "foobar" to address: <system specific error> ERROR: connection to the remote node postgres@foobar:57636 failed with the following error: could not translate host name "foobar" to address: <system specific error>
WITH cte_1 AS (SELECT * FROM event_responses LIMIT 1) SELECT count(*) FROM cte_1; WITH cte_1 AS (SELECT * FROM event_responses LIMIT 1) SELECT count(*) FROM cte_1;
ERROR: connection to the remote node foobar:57636 failed with the following error: could not translate host name "foobar" to address: <system specific error> ERROR: connection to the remote node postgres@foobar:57636 failed with the following error: could not translate host name "foobar" to address: <system specific error>
ALTER SYSTEM RESET citus.local_hostname; ALTER SYSTEM RESET citus.local_hostname;
SELECT pg_reload_conf(); SELECT pg_reload_conf();
pg_reload_conf pg_reload_conf

View File

@ -3281,9 +3281,9 @@ SELECT pg_sleep(0.1); -- wait to make sure the config has changed before running
SET citus.enable_local_execution TO false; -- force a connection to the dummy placements SET citus.enable_local_execution TO false; -- force a connection to the dummy placements
-- run queries that use dummy placements for local execution -- run queries that use dummy placements for local execution
SELECT * FROM event_responses WHERE FALSE; SELECT * FROM event_responses WHERE FALSE;
ERROR: connection to the remote node foobar:57636 failed with the following error: could not translate host name "foobar" to address: <system specific error> ERROR: connection to the remote node postgres@foobar:57636 failed with the following error: could not translate host name "foobar" to address: <system specific error>
WITH cte_1 AS (SELECT * FROM event_responses LIMIT 1) SELECT count(*) FROM cte_1; WITH cte_1 AS (SELECT * FROM event_responses LIMIT 1) SELECT count(*) FROM cte_1;
ERROR: connection to the remote node foobar:57636 failed with the following error: could not translate host name "foobar" to address: <system specific error> ERROR: connection to the remote node postgres@foobar:57636 failed with the following error: could not translate host name "foobar" to address: <system specific error>
ALTER SYSTEM RESET citus.local_hostname; ALTER SYSTEM RESET citus.local_hostname;
SELECT pg_reload_conf(); SELECT pg_reload_conf();
pg_reload_conf pg_reload_conf

View File

@ -587,7 +587,7 @@ SET client_min_messages TO DEBUG;
-- verify that we can create connections only with users with login privileges. -- verify that we can create connections only with users with login privileges.
SET ROLE role_without_login; SET ROLE role_without_login;
SELECT citus_check_connection_to_node('localhost', :worker_1_port); SELECT citus_check_connection_to_node('localhost', :worker_1_port);
WARNING: connection to the remote node localhost:xxxxx failed with the following error: FATAL: role "role_without_login" is not permitted to log in WARNING: connection to the remote node role_without_login@localhost:xxxxx failed with the following error: FATAL: role "role_without_login" is not permitted to log in
citus_check_connection_to_node citus_check_connection_to_node
--------------------------------------------------------------------- ---------------------------------------------------------------------
f f

View File

@ -730,7 +730,7 @@ ALTER USER test_user WITH nologin;
\c - test_user - :master_port \c - test_user - :master_port
-- reissue copy, and it should fail -- reissue copy, and it should fail
COPY numbers_hash FROM STDIN WITH (FORMAT 'csv'); COPY numbers_hash FROM STDIN WITH (FORMAT 'csv');
ERROR: connection to the remote node localhost:xxxxx failed with the following error: FATAL: role "test_user" is not permitted to log in ERROR: connection to the remote node test_user@localhost:xxxxx failed with the following error: FATAL: role "test_user" is not permitted to log in
-- verify shards in the none of the workers as marked invalid -- verify shards in the none of the workers as marked invalid
SELECT shardid, shardstate, nodename, nodeport SELECT shardid, shardstate, nodename, nodeport
FROM pg_dist_shard_placement join pg_dist_shard using(shardid) FROM pg_dist_shard_placement join pg_dist_shard using(shardid)
@ -749,7 +749,7 @@ SELECT shardid, shardstate, nodename, nodeport
-- try to insert into a reference table copy should fail -- try to insert into a reference table copy should fail
COPY numbers_reference FROM STDIN WITH (FORMAT 'csv'); COPY numbers_reference FROM STDIN WITH (FORMAT 'csv');
ERROR: connection to the remote node localhost:xxxxx failed with the following error: FATAL: role "test_user" is not permitted to log in ERROR: connection to the remote node test_user@localhost:xxxxx failed with the following error: FATAL: role "test_user" is not permitted to log in
-- verify shards for reference table are still valid -- verify shards for reference table are still valid
SELECT shardid, shardstate, nodename, nodeport SELECT shardid, shardstate, nodename, nodeport
FROM pg_dist_shard_placement join pg_dist_shard using(shardid) FROM pg_dist_shard_placement join pg_dist_shard using(shardid)
@ -765,7 +765,7 @@ SELECT shardid, shardstate, nodename, nodeport
-- since it can not insert into either copies of a shard. shards are expected to -- since it can not insert into either copies of a shard. shards are expected to
-- stay valid since the operation is rolled back. -- stay valid since the operation is rolled back.
COPY numbers_hash_other FROM STDIN WITH (FORMAT 'csv'); COPY numbers_hash_other FROM STDIN WITH (FORMAT 'csv');
ERROR: connection to the remote node localhost:xxxxx failed with the following error: FATAL: role "test_user" is not permitted to log in ERROR: connection to the remote node test_user@localhost:xxxxx failed with the following error: FATAL: role "test_user" is not permitted to log in
-- verify shards for numbers_hash_other are still valid -- verify shards for numbers_hash_other are still valid
-- since copy has failed altogether -- since copy has failed altogether
SELECT shardid, shardstate, nodename, nodeport SELECT shardid, shardstate, nodename, nodeport

View File

@ -1207,15 +1207,15 @@ NOTICE: not propagating ALTER ROLE ... RENAME TO commands to worker nodes
SET search_path TO multi_modifying_xacts; SET search_path TO multi_modifying_xacts;
-- should fail since the worker doesn't have test_user anymore -- should fail since the worker doesn't have test_user anymore
INSERT INTO reference_failure_test VALUES (1, '1'); INSERT INTO reference_failure_test VALUES (1, '1');
ERROR: connection to the remote node localhost:xxxxx failed with the following error: FATAL: role "test_user" does not exist ERROR: connection to the remote node test_user@localhost:xxxxx failed with the following error: FATAL: role "test_user" does not exist
-- the same as the above, but wrapped within a transaction -- the same as the above, but wrapped within a transaction
BEGIN; BEGIN;
INSERT INTO reference_failure_test VALUES (1, '1'); INSERT INTO reference_failure_test VALUES (1, '1');
ERROR: connection to the remote node localhost:xxxxx failed with the following error: FATAL: role "test_user" does not exist ERROR: connection to the remote node test_user@localhost:xxxxx failed with the following error: FATAL: role "test_user" does not exist
COMMIT; COMMIT;
BEGIN; BEGIN;
COPY reference_failure_test FROM STDIN WITH (FORMAT 'csv'); COPY reference_failure_test FROM STDIN WITH (FORMAT 'csv');
ERROR: connection to the remote node localhost:xxxxx failed with the following error: FATAL: role "test_user" does not exist ERROR: connection to the remote node test_user@localhost:xxxxx failed with the following error: FATAL: role "test_user" does not exist
COMMIT; COMMIT;
-- show that no data go through the table and shard states are good -- show that no data go through the table and shard states are good
SET client_min_messages to 'ERROR'; SET client_min_messages to 'ERROR';
@ -1241,7 +1241,7 @@ ORDER BY s.logicalrelid, sp.shardstate;
-- any failure rollbacks the transaction -- any failure rollbacks the transaction
BEGIN; BEGIN;
COPY numbers_hash_failure_test FROM STDIN WITH (FORMAT 'csv'); COPY numbers_hash_failure_test FROM STDIN WITH (FORMAT 'csv');
ERROR: connection to the remote node localhost:xxxxx failed with the following error: FATAL: role "test_user" does not exist ERROR: connection to the remote node test_user@localhost:xxxxx failed with the following error: FATAL: role "test_user" does not exist
ABORT; ABORT;
-- none of placements are invalid after abort -- none of placements are invalid after abort
SELECT shardid, shardstate, nodename, nodeport SELECT shardid, shardstate, nodename, nodeport
@ -1262,8 +1262,8 @@ ORDER BY shardid, nodeport;
-- verify nothing is inserted -- verify nothing is inserted
SELECT count(*) FROM numbers_hash_failure_test; SELECT count(*) FROM numbers_hash_failure_test;
WARNING: connection to the remote node localhost:xxxxx failed with the following error: FATAL: role "test_user" does not exist WARNING: connection to the remote node test_user@localhost:xxxxx failed with the following error: FATAL: role "test_user" does not exist
WARNING: connection to the remote node localhost:xxxxx failed with the following error: FATAL: role "test_user" does not exist WARNING: connection to the remote node test_user@localhost:xxxxx failed with the following error: FATAL: role "test_user" does not exist
count count
--------------------------------------------------------------------- ---------------------------------------------------------------------
0 0
@ -1289,7 +1289,7 @@ ORDER BY shardid, nodeport;
-- all failures roll back the transaction -- all failures roll back the transaction
BEGIN; BEGIN;
COPY numbers_hash_failure_test FROM STDIN WITH (FORMAT 'csv'); COPY numbers_hash_failure_test FROM STDIN WITH (FORMAT 'csv');
ERROR: connection to the remote node localhost:xxxxx failed with the following error: FATAL: role "test_user" does not exist ERROR: connection to the remote node test_user@localhost:xxxxx failed with the following error: FATAL: role "test_user" does not exist
COMMIT; COMMIT;
-- expect none of the placements to be market invalid after commit -- expect none of the placements to be market invalid after commit
SELECT shardid, shardstate, nodename, nodeport SELECT shardid, shardstate, nodename, nodeport
@ -1310,8 +1310,8 @@ ORDER BY shardid, nodeport;
-- verify no data is inserted -- verify no data is inserted
SELECT count(*) FROM numbers_hash_failure_test; SELECT count(*) FROM numbers_hash_failure_test;
WARNING: connection to the remote node localhost:xxxxx failed with the following error: FATAL: role "test_user" does not exist WARNING: connection to the remote node test_user@localhost:xxxxx failed with the following error: FATAL: role "test_user" does not exist
WARNING: connection to the remote node localhost:xxxxx failed with the following error: FATAL: role "test_user" does not exist WARNING: connection to the remote node test_user@localhost:xxxxx failed with the following error: FATAL: role "test_user" does not exist
count count
--------------------------------------------------------------------- ---------------------------------------------------------------------
0 0
@ -1326,7 +1326,7 @@ NOTICE: not propagating ALTER ROLE ... RENAME TO commands to worker nodes
SET search_path TO multi_modifying_xacts; SET search_path TO multi_modifying_xacts;
-- fails on all shard placements -- fails on all shard placements
INSERT INTO numbers_hash_failure_test VALUES (2,2); INSERT INTO numbers_hash_failure_test VALUES (2,2);
ERROR: connection to the remote node localhost:xxxxx failed with the following error: FATAL: role "test_user" does not exist ERROR: connection to the remote node test_user@localhost:xxxxx failed with the following error: FATAL: role "test_user" does not exist
-- connect back to the master with the proper user to continue the tests -- connect back to the master with the proper user to continue the tests
\c - :default_user - :master_port \c - :default_user - :master_port
SET search_path TO multi_modifying_xacts; SET search_path TO multi_modifying_xacts;

View File

@ -82,7 +82,7 @@ GRANT ALL ON TABLE lineitem, orders, lineitem, customer, nation, part, supplier
\c :alice_conninfo \c :alice_conninfo
-- router query (should break because of bad password) -- router query (should break because of bad password)
INSERT INTO customer VALUES (12345, 'name', NULL, 5, 'phone', 123.45, 'segment', 'comment'); INSERT INTO customer VALUES (12345, 'name', NULL, 5, 'phone', 123.45, 'segment', 'comment');
ERROR: connection to the remote node localhost:xxxxx failed with the following error: FATAL: password authentication failed for user "alice" ERROR: connection to the remote node alice@localhost:xxxxx failed with the following error: FATAL: password authentication failed for user "alice"
-- fix alice's worker1 password ... -- fix alice's worker1 password ...
UPDATE pg_dist_authinfo UPDATE pg_dist_authinfo
SET authinfo = ('password=' || :'alice_worker_1_pw') SET authinfo = ('password=' || :'alice_worker_1_pw')

View File

@ -2703,10 +2703,10 @@ SET search_path TO multi_router_planner;
-- still, we never mark placements inactive. Instead, fail the transaction -- still, we never mark placements inactive. Instead, fail the transaction
BEGIN; BEGIN;
INSERT INTO failure_test VALUES (1, 1); INSERT INTO failure_test VALUES (1, 1);
ERROR: connection to the remote node localhost:xxxxx failed with the following error: FATAL: role "router_user" does not exist ERROR: connection to the remote node router_user@localhost:xxxxx failed with the following error: FATAL: role "router_user" does not exist
ROLLBACK; ROLLBACK;
INSERT INTO failure_test VALUES (2, 1); INSERT INTO failure_test VALUES (2, 1);
ERROR: connection to the remote node localhost:xxxxx failed with the following error: FATAL: role "router_user" does not exist ERROR: connection to the remote node router_user@localhost:xxxxx failed with the following error: FATAL: role "router_user" does not exist
SELECT shardid, shardstate, nodename, nodeport FROM pg_dist_shard_placement SELECT shardid, shardstate, nodename, nodeport FROM pg_dist_shard_placement
WHERE shardid IN ( WHERE shardid IN (
SELECT shardid FROM pg_dist_shard SELECT shardid FROM pg_dist_shard

View File

@ -47,7 +47,7 @@ show citus.node_conninfo;
-- Should give a connection error because of bad sslmode -- Should give a connection error because of bad sslmode
select count(*) from test where a = 0; select count(*) from test where a = 0;
ERROR: connection to the remote node localhost:xxxxx failed with the following error: invalid sslmode value: "doesnotexist" ERROR: connection to the remote node postgres@localhost:xxxxx failed with the following error: invalid sslmode value: "doesnotexist"
-- Reset it again -- Reset it again
ALTER SYSTEM RESET citus.node_conninfo; ALTER SYSTEM RESET citus.node_conninfo;
select pg_reload_conf(); select pg_reload_conf();
@ -118,7 +118,7 @@ select count(*) from test where a = 0;
COMMIT; COMMIT;
-- Should fail now with connection error, when transaction is finished -- Should fail now with connection error, when transaction is finished
select count(*) from test where a = 0; select count(*) from test where a = 0;
ERROR: connection to the remote node localhost:xxxxx failed with the following error: invalid sslmode value: "doesnotexist" ERROR: connection to the remote node postgres@localhost:xxxxx failed with the following error: invalid sslmode value: "doesnotexist"
-- Reset it again -- Reset it again
ALTER SYSTEM RESET citus.node_conninfo; ALTER SYSTEM RESET citus.node_conninfo;
select pg_reload_conf(); select pg_reload_conf();
@ -181,7 +181,7 @@ COMMIT;
-- Should fail now, when transaction is finished -- Should fail now, when transaction is finished
SET client_min_messages TO ERROR; SET client_min_messages TO ERROR;
select count(*) from test where a = 0; select count(*) from test where a = 0;
ERROR: connection to the remote node localhost:xxxxx failed with the following error: invalid sslmode value: "doesnotexist" ERROR: connection to the remote node postgres@localhost:xxxxx failed with the following error: invalid sslmode value: "doesnotexist"
RESET client_min_messages; RESET client_min_messages;
-- Reset it again -- Reset it again
ALTER SYSTEM RESET citus.node_conninfo; ALTER SYSTEM RESET citus.node_conninfo;
@ -235,11 +235,11 @@ show citus.node_conninfo;
-- Should fail since a different shard is accessed and thus a new connection -- Should fail since a different shard is accessed and thus a new connection
-- will to be created. -- will to be created.
select count(*) from test where a = 0; select count(*) from test where a = 0;
ERROR: connection to the remote node localhost:xxxxx failed with the following error: invalid sslmode value: "doesnotexist" ERROR: connection to the remote node postgres@localhost:xxxxx failed with the following error: invalid sslmode value: "doesnotexist"
COMMIT; COMMIT;
-- Should still fail now, when transaction is finished -- Should still fail now, when transaction is finished
select count(*) from test where a = 0; select count(*) from test where a = 0;
ERROR: connection to the remote node localhost:xxxxx failed with the following error: invalid sslmode value: "doesnotexist" ERROR: connection to the remote node postgres@localhost:xxxxx failed with the following error: invalid sslmode value: "doesnotexist"
-- Reset it again -- Reset it again
ALTER SYSTEM RESET citus.node_conninfo; ALTER SYSTEM RESET citus.node_conninfo;
select pg_reload_conf(); select pg_reload_conf();
@ -301,7 +301,7 @@ COMMIT;
-- Should fail now, when transaction is finished -- Should fail now, when transaction is finished
SET client_min_messages TO ERROR; SET client_min_messages TO ERROR;
select count(*) from test; select count(*) from test;
ERROR: connection to the remote node localhost:xxxxx failed with the following error: invalid sslmode value: "doesnotexist" ERROR: connection to the remote node postgres@localhost:xxxxx failed with the following error: invalid sslmode value: "doesnotexist"
RESET client_min_messages; RESET client_min_messages;
-- Reset it again -- Reset it again
ALTER SYSTEM RESET citus.node_conninfo; ALTER SYSTEM RESET citus.node_conninfo;
@ -359,7 +359,7 @@ ROLLBACK;
-- Should fail now, when transaction is finished -- Should fail now, when transaction is finished
SET client_min_messages TO ERROR; SET client_min_messages TO ERROR;
select count(*) from test; select count(*) from test;
ERROR: connection to the remote node localhost:xxxxx failed with the following error: invalid sslmode value: "doesnotexist" ERROR: connection to the remote node postgres@localhost:xxxxx failed with the following error: invalid sslmode value: "doesnotexist"
RESET client_min_messages; RESET client_min_messages;
-- Reset it again -- Reset it again
ALTER SYSTEM RESET citus.node_conninfo; ALTER SYSTEM RESET citus.node_conninfo;
@ -497,7 +497,7 @@ ALTER TABLE test ADD COLUMN c INT;
COMMIT; COMMIT;
-- Should fail now, when transaction is finished -- Should fail now, when transaction is finished
ALTER TABLE test ADD COLUMN d INT; ALTER TABLE test ADD COLUMN d INT;
ERROR: connection to the remote node localhost:xxxxx failed with the following error: invalid sslmode value: "doesnotexist" ERROR: connection to the remote node postgres@localhost:xxxxx failed with the following error: invalid sslmode value: "doesnotexist"
-- Reset it again -- Reset it again
ALTER SYSTEM RESET citus.node_conninfo; ALTER SYSTEM RESET citus.node_conninfo;
select pg_reload_conf(); select pg_reload_conf();

View File

@ -127,7 +127,7 @@ SELECT pg_sleep(.1); -- wait to make sure the config has changed before running
(1 row) (1 row)
SELECT master_drain_node('localhost', :master_port); SELECT master_drain_node('localhost', :master_port);
ERROR: connection to the remote node foobar:57636 failed with the following error: could not translate host name "foobar" to address: <system specific error> ERROR: connection to the remote node postgres@foobar:57636 failed with the following error: could not translate host name "foobar" to address: <system specific error>
CALL citus_cleanup_orphaned_resources(); CALL citus_cleanup_orphaned_resources();
ALTER SYSTEM RESET citus.local_hostname; ALTER SYSTEM RESET citus.local_hostname;
SELECT pg_reload_conf(); SELECT pg_reload_conf();
@ -197,7 +197,7 @@ SELECT pg_sleep(.1); -- wait to make sure the config has changed before running
(1 row) (1 row)
SELECT replicate_table_shards('dist_table_test_2', max_shard_copies := 4, shard_transfer_mode:='block_writes'); SELECT replicate_table_shards('dist_table_test_2', max_shard_copies := 4, shard_transfer_mode:='block_writes');
ERROR: connection to the remote node foobar:57636 failed with the following error: could not translate host name "foobar" to address: <system specific error> ERROR: connection to the remote node postgres@foobar:57636 failed with the following error: could not translate host name "foobar" to address: <system specific error>
ALTER SYSTEM RESET citus.local_hostname; ALTER SYSTEM RESET citus.local_hostname;
SELECT pg_reload_conf(); SELECT pg_reload_conf();
pg_reload_conf pg_reload_conf
@ -681,7 +681,7 @@ FROM (
FROM pg_dist_shard FROM pg_dist_shard
WHERE logicalrelid = 'rebalance_test_table'::regclass WHERE logicalrelid = 'rebalance_test_table'::regclass
) T; ) T;
ERROR: connection to the remote node foobar:57636 failed with the following error: could not translate host name "foobar" to address: <system specific error> ERROR: connection to the remote node postgres@foobar:57636 failed with the following error: could not translate host name "foobar" to address: <system specific error>
CALL citus_cleanup_orphaned_resources(); CALL citus_cleanup_orphaned_resources();
ALTER SYSTEM RESET citus.local_hostname; ALTER SYSTEM RESET citus.local_hostname;
SELECT pg_reload_conf(); SELECT pg_reload_conf();

View File

@ -34,9 +34,9 @@ SELECT * FROM shards_in_workers;
-- Failure on creating the subscription -- Failure on creating the subscription
-- Failing exactly on CREATE SUBSCRIPTION is causing flaky test where we fail with either: -- Failing exactly on CREATE SUBSCRIPTION is causing flaky test where we fail with either:
-- 1) ERROR: connection to the remote node localhost:xxxxx failed with the following error: ERROR: subscription "citus_shard_move_subscription_xxxxxxx" does not exist -- 1) ERROR: connection to the remote node postgres@localhost:xxxxx failed with the following error: ERROR: subscription "citus_shard_move_subscription_xxxxxxx" does not exist
-- another command is already in progress -- another command is already in progress
-- 2) ERROR: connection to the remote node localhost:xxxxx failed with the following error: another command is already in progress -- 2) ERROR: connection to the remote node postgres@localhost:xxxxx failed with the following error: another command is already in progress
-- Instead fail on the next step (ALTER SUBSCRIPTION) instead which is also required logically as part of uber CREATE SUBSCRIPTION operation. -- Instead fail on the next step (ALTER SUBSCRIPTION) instead which is also required logically as part of uber CREATE SUBSCRIPTION operation.
SELECT citus.mitmproxy('conn.onQuery(query="ALTER SUBSCRIPTION").kill()'); SELECT citus.mitmproxy('conn.onQuery(query="ALTER SUBSCRIPTION").kill()');