Dear Amit,
> However, if required, we can
> move LogStandbySnapshot() and XLogFlush() outside the loop similar to
> 16 and above branches. OTOH, doing minimal changes in bank branches
> and that too in 15 and 14 to fix this issue seems like a prudent
> choice.
Per my understanding, minimizing the code changes for backbracnhes is more
important unless it is really needed.
I cannot come up with cases in core that other processes acquire {all partitions of locks,
ProcArrayLock, XidGenLock} first then ReplicationSlotAllocationLock, which can cause
deadlocks.
We cannot completely ensure all extensions because some of them may be
proprietary one, but such extensions rarely exist.
We can fix later if someone reports such deadlocks.
Best regards,
Hayato Kuroda
FUJITSU LIMITED