=== Applying patches on top of PostgreSQL commit ID 4d936c3fff1ac8dead2cc240ba3da2ed6337257c === /etc/rc.d/jail: WARNING: Per-jail configuration via jail_* variables is obsolete. Please consider migrating to /etc/jail.conf. Fri Dec 5 16:17:22 UTC 2025 On branch cf/5734 nothing to commit, working tree clean === using 'git am' to apply patch ./v3-0001-Fix-bug-that-could-block-the-startup-of-parallel-.patch === Applying: Fix bug that could block the startup of parallel apply workers. Using index info to reconstruct a base tree... M src/backend/replication/logical/launcher.c Falling back to patching base and 3-way merge... Auto-merging src/backend/replication/logical/launcher.c CONFLICT (content): Merge conflict in src/backend/replication/logical/launcher.c error: Failed to merge in the changes. hint: Use 'git am --show-current-patch=diff' to see the failed patch Patch failed at 0001 Fix bug that could block the startup of parallel apply workers. When you have resolved this problem, run "git am --continue". If you prefer to skip this patch, run "git am --skip" instead. To restore the original branch and stop patching, run "git am --abort". Unstaged changes after reset: M src/backend/replication/logical/launcher.c === using patch(1) to apply patch ./v3-0001-Fix-bug-that-could-block-the-startup-of-parallel-.patch === patching file src/backend/replication/logical/launcher.c Hunk #1 succeeded at 97 (offset 1 line). Hunk #2 succeeded at 382 (offset 32 lines). Hunk #3 succeeded at 437 (offset 33 lines). Hunk #4 FAILED at 847. 1 out of 4 hunks FAILED -- saving rejects to file src/backend/replication/logical/launcher.c.rej Unstaged changes after reset: M src/backend/replication/logical/launcher.c Removing src/backend/replication/logical/launcher.c.rej === using 'git apply' to apply patch ./v3-0001-Fix-bug-that-could-block-the-startup-of-parallel-.patch === Applied patch to 'src/backend/replication/logical/launcher.c' with conflicts. U src/backend/replication/logical/launcher.c diff --cc src/backend/replication/logical/launcher.c index fdf1ccad462,ac95afe4bae..00000000000 --- a/src/backend/replication/logical/launcher.c +++ b/src/backend/replication/logical/launcher.c @@@ -926,20 -847,9 +929,23 @@@ logicalrep_worker_onexit(int code, Datu int logicalrep_sync_worker_count(Oid subid) { - int i; int res = 0; ++<<<<<<< ours + Assert(LWLockHeldByMe(LogicalRepWorkerLock)); + + /* Search for attached worker for a given subscription id. */ + for (i = 0; i < max_logical_replication_workers; i++) + { + LogicalRepWorker *w = &LogicalRepCtx->workers[i]; + + if (w->subid == subid && (isTableSyncWorker(w) || isSequenceSyncWorker(w))) + res++; + } + ++======= + logicalrep_worker_count(subid, &res, NULL); ++>>>>>>> theirs return res; }