On Tue, Feb 3, 2026 at 12:38 PM Chao Li <li.evan.chao@gmail.com> wrote:
> > I think we cannot assume the slot type here. A suitable checking might
> > be: If a physical slot was acquired during logical replication, report an error,
> > just like we do in StartReplication().
>
> Good point. In StartReplication(), we check MyReplicationSlot is not logical, correspondingly, in
StartLogicalReplication(),we should check MyReplicationSlot is not physical.
StartLogicalReplication() calls CreateDecodingContext() after
ReplicationSlotAcquire(), and CreateDecodingContext() seems to
already perform this check. Isn't that sufficient?
Regards,
--
Fujii Masao