diff --git a/src/test/cluster_tap/t/004_backend_types.pl b/src/test/cluster_tap/t/004_backend_types.pl index 5c1c4b5366..376f8f302d 100644 --- a/src/test/cluster_tap/t/004_backend_types.pl +++ b/src/test/cluster_tap/t/004_backend_types.pl @@ -95,12 +95,21 @@ q{SELECT count(*) FROM pg_stat_activity WHERE backend_type IN ( 'heartbeat', 'interconnect listener', - 'lms worker', 'managed recovery process', 'recovery coordinator', 'recovery worker', 'sinval broadcaster', 'tt gc')}); is($pgrac_visible, '0', 'no pgrac process descriptor visible except spawned skeletons (others deferred to Stage 2-6)'); +# spec-7.3 D2: the LMS DATA-plane worker pool ships with a default of +# cluster.lms_workers = 2 -- worker 0 stays the historic 'lms' process and +# workers 1..N-1 run as 'lms worker' aux processes, so exactly ONE +# 'lms worker' descriptor is a spawned skeleton now (not deferred). +my $lms_worker_visible = $node->safe_psql( + 'postgres', + q{SELECT count(*) FROM pg_stat_activity WHERE backend_type = 'lms worker'}); +is($lms_worker_visible, '1', + 'default LMS pool spawns exactly one lms worker aux process (spec-7.3 D2)'); + # LMON is spawned by postmaster (spec-1.11 Sprint A). Verify it # appears in pg_stat_activity exactly once. my $lmon_visible = $node->safe_psql( diff --git a/src/test/cluster_tap/t/078_ic_tier1_partial_send_recv.pl b/src/test/cluster_tap/t/078_ic_tier1_partial_send_recv.pl index 823cbd5e76..cdf69fab2f 100644 --- a/src/test/cluster_tap/t/078_ic_tier1_partial_send_recv.pl +++ b/src/test/cluster_tap/t/078_ic_tier1_partial_send_recv.pl @@ -61,6 +61,12 @@ sub build_hello $node->append_conf('postgresql.conf', "cluster.enabled = on\n"); $node->append_conf('postgresql.conf', "cluster.interconnect_tier = tier1\n"); $node->append_conf('postgresql.conf', "cluster.node_id = 0\n"); +# spec-7.3 merge: this hand-rolled rig reserves ONE data port per node; the +# shipped default cluster.lms_workers=2 binds [data_port, data_port+1] and +# cross-wires consecutive free ports (HELLO DATA worker mismatch). Pin the +# pool to one worker: N=1 is the spec-7.2 topology identity this rig was +# written against. +$node->append_conf('postgresql.conf', "cluster.lms_workers = 1\n"); $node->append_conf('postgresql.conf', "cluster.allow_single_node = on\n"); # Declare 2 nodes so we can spoof "peer 1" connecting to "peer 0" (us). diff --git a/src/test/cluster_tap/t/288_cf_enqueue_concurrent.pl b/src/test/cluster_tap/t/288_cf_enqueue_concurrent.pl index a4f14e62b3..f83f97ffe6 100644 --- a/src/test/cluster_tap/t/288_cf_enqueue_concurrent.pl +++ b/src/test/cluster_tap/t/288_cf_enqueue_concurrent.pl @@ -126,6 +126,13 @@ sub cf_counter $node0->append_conf('postgresql.conf', "cluster.node_id = 0\n"); $node1->append_conf('postgresql.conf', $common_conf); $node1->append_conf('postgresql.conf', "cluster.node_id = 1\n"); +# spec-7.3 merge: this hand-rolled rig reserves ONE data port per node; the +# shipped default cluster.lms_workers=2 binds [data_port, data_port+1] and +# cross-wires consecutive free ports (HELLO DATA worker mismatch). Pin the +# pool to one worker: N=1 is the spec-7.2 topology identity this rig was +# written against. +$node0->append_conf('postgresql.conf', "cluster.lms_workers = 1\n"); +$node1->append_conf('postgresql.conf', "cluster.lms_workers = 1\n"); my $pgrac_conf = <append_conf('postgresql.conf', "cluster.node_id = 0\n"); $node1->append_conf('postgresql.conf', $common_conf); $node1->append_conf('postgresql.conf', "cluster.node_id = 1\n"); +# spec-7.3 merge: this hand-rolled rig reserves ONE data port per node; the +# shipped default cluster.lms_workers=2 binds [data_port, data_port+1] and +# cross-wires consecutive free ports (HELLO DATA worker mismatch). Pin the +# pool to one worker: N=1 is the spec-7.2 topology identity this rig was +# written against. +$node0->append_conf('postgresql.conf', "cluster.lms_workers = 1\n"); +$node1->append_conf('postgresql.conf', "cluster.lms_workers = 1\n"); my $pgrac_conf = <node0, $pair->node1) { $node->adjust_conf('postgresql.conf', 'cluster.interconnect_tier', 'tier3'); + # spec-7.3 merge: this rig rewrites pgrac.conf with ONE data port per + # node; pin the pool to one worker (N=1 = spec-7.2 topology identity). + $node->adjust_conf('postgresql.conf', 'cluster.lms_workers', '1'); } sub write_rdma_pgrac_conf diff --git a/src/test/cluster_tap/t/335_adg_two_thread_rfs_apply.pl b/src/test/cluster_tap/t/335_adg_two_thread_rfs_apply.pl index 2e1c4a0a89..644dde0e83 100644 --- a/src/test/cluster_tap/t/335_adg_two_thread_rfs_apply.pl +++ b/src/test/cluster_tap/t/335_adg_two_thread_rfs_apply.pl @@ -291,6 +291,15 @@ sub wait_for_log_match_from 'cluster.adg_rfs_conninfos = ' . quote_conf($rfs_conninfos) . "\n"); $standby1->append_conf('postgresql.conf', $standby_common_conf); $standby1->append_conf('postgresql.conf', "cluster.node_id = 1\n"); +# spec-7.3 merge: this hand-rolled rig reserves ONE data port per node; the +# shipped default cluster.lms_workers=2 binds [data_port, data_port+1] and +# cross-wires consecutive free ports (HELLO DATA worker mismatch). Pin the +# pool to one worker: N=1 is the spec-7.2 topology identity this rig was +# written against. +$primary0->append_conf('postgresql.conf', "cluster.lms_workers = 1\n"); +$primary1->append_conf('postgresql.conf', "cluster.lms_workers = 1\n"); +$standby0->append_conf('postgresql.conf', "cluster.lms_workers = 1\n"); +$standby1->append_conf('postgresql.conf', "cluster.lms_workers = 1\n"); write_pair_conf($standby0, $standby1, 'adg2_standby'); $standby0->start; diff --git a/src/test/cluster_tap/t/336_cluster_backup_pitr.pl b/src/test/cluster_tap/t/336_cluster_backup_pitr.pl index 660ddb5f0f..26ed2fb77c 100644 --- a/src/test/cluster_tap/t/336_cluster_backup_pitr.pl +++ b/src/test/cluster_tap/t/336_cluster_backup_pitr.pl @@ -34,6 +34,7 @@ $node->append_conf('postgresql.conf', "cluster.enabled = on\n" . "cluster.node_id = 0\n" + . "cluster.lms_workers = 1\n" . "cluster.allow_single_node = on\n" . "wal_level = replica\n" . "archive_mode = on\n" @@ -466,6 +467,7 @@ sub configure_pair_restore . "restore_command = 'cp $pair_archive/%f %p'\n" . "cluster.enabled = on\n" . "cluster.node_id = 0\n" + . "cluster.lms_workers = 1\n" . "cluster.allow_single_node = on\n" . "cluster.voting_disks = ''\n" . "cluster.wal_threads_dir = ''\n" @@ -605,6 +607,7 @@ sub wait_for_pair_restore_promotion $bad_target_node->append_conf('postgresql.conf', "cluster.enabled = on\n" . "cluster.node_id = 0\n" + . "cluster.lms_workers = 1\n" . "cluster.allow_single_node = on\n" . "wal_level = replica\n" . "cluster.recovery_target_scn = '0'\n"); @@ -624,6 +627,7 @@ sub wait_for_pair_restore_promotion $multi_target_node->append_conf('postgresql.conf', "cluster.enabled = on\n" . "cluster.node_id = 0\n" + . "cluster.lms_workers = 1\n" . "cluster.allow_single_node = on\n" . "wal_level = replica\n" . "cluster.recovery_target_scn = '1'\n" @@ -645,6 +649,7 @@ sub wait_for_pair_restore_promotion $pin_node->append_conf('postgresql.conf', "cluster.enabled = on\n" . "cluster.node_id = 0\n" + . "cluster.lms_workers = 1\n" . "cluster.allow_single_node = on\n" . "wal_level = replica\n" . "archive_mode = on\n" diff --git a/src/test/cluster_tap/t/337_shared_catalog_ddl_2node.pl b/src/test/cluster_tap/t/337_shared_catalog_ddl_2node.pl index 6db3cccd8b..26c4881a64 100644 --- a/src/test/cluster_tap/t/337_shared_catalog_ddl_2node.pl +++ b/src/test/cluster_tap/t/337_shared_catalog_ddl_2node.pl @@ -201,6 +201,13 @@ $node1->append_conf('postgresql.conf', $sc_common); $node1->append_conf('postgresql.conf', $cluster_conf); $node1->append_conf('postgresql.conf', "cluster.node_id = 1\n"); +# spec-7.3 merge: this hand-rolled rig reserves ONE data port per node; the +# shipped default cluster.lms_workers=2 binds [data_port, data_port+1] and +# cross-wires consecutive free ports (HELLO DATA worker mismatch). Pin the +# pool to one worker: N=1 is the spec-7.2 topology identity this rig was +# written against. +$node0->append_conf('postgresql.conf', "cluster.lms_workers = 1\n"); +$node1->append_conf('postgresql.conf', "cluster.lms_workers = 1\n"); my $pgrac_conf = <append_conf('postgresql.conf', $sc_common); $node1->append_conf('postgresql.conf', $cluster_conf); $node1->append_conf('postgresql.conf', "cluster.node_id = 1\n"); +# spec-7.3 merge: this hand-rolled rig reserves ONE data port per node; the +# shipped default cluster.lms_workers=2 binds [data_port, data_port+1] and +# cross-wires consecutive free ports (HELLO DATA worker mismatch). Pin the +# pool to one worker: N=1 is the spec-7.2 topology identity this rig was +# written against. +$node0->append_conf('postgresql.conf', "cluster.lms_workers = 1\n"); +$node1->append_conf('postgresql.conf', "cluster.lms_workers = 1\n"); my $pgrac_conf = <append_conf('postgresql.conf', $sc_common); $node1->append_conf('postgresql.conf', $cluster_conf); $node1->append_conf('postgresql.conf', "cluster.node_id = 1\n"); +# spec-7.3 merge: this hand-rolled rig reserves ONE data port per node; the +# shipped default cluster.lms_workers=2 binds [data_port, data_port+1] and +# cross-wires consecutive free ports (HELLO DATA worker mismatch). Pin the +# pool to one worker: N=1 is the spec-7.2 topology identity this rig was +# written against. +$node0->append_conf('postgresql.conf', "cluster.lms_workers = 1\n"); +$node1->append_conf('postgresql.conf', "cluster.lms_workers = 1\n"); my $pgrac_conf = <