Avoid useless ReplicationOriginExitCleanup locking
authorAlvaro Herrera <alvherre@alvh.no-ip.org>
Mon, 15 Jan 2024 12:02:03 +0000 (13:02 +0100)
committerAlvaro Herrera <alvherre@alvh.no-ip.org>
Mon, 15 Jan 2024 12:02:03 +0000 (13:02 +0100)
commitaa817c7496575b37fde6ea5e0cd65b26f29ea532
treeaf1b36f38520ce57a312d89aceb48ef62f34f525
parent31acee4b66f9f88ad5c19c1276252688bdaa95c9
Avoid useless ReplicationOriginExitCleanup locking

When session_replication_state is NULL, we can know there's nothing to
do with no lock acquisition.  Do that.

Author: Bharath Rupireddy <bharath.rupireddyforpostgres@gmail.com>
Discussion: https://postgr.es/m/CALj2ACX+YaeRU5xJqR4C7kLsTO_F7DBRNF8WgeHvJZcKtNuK_A@mail.gmail.com
src/backend/replication/logical/origin.c