Don't wake up logical replication launcher unnecessarily

In CREATE SUBSCRIPTION, only wake up the launcher when the subscription
is enabled.

Author: Fujii Masao <masao.fujii@gmail.com>
This commit is contained in:
Peter Eisentraut 2017-05-01 22:50:32 -04:00
parent 54affb41e7
commit a99448ab45
1 changed files with 2 additions and 1 deletions

View File

@ -452,7 +452,8 @@ CreateSubscription(CreateSubscriptionStmt *stmt, bool isTopLevel)
heap_close(rel, RowExclusiveLock);
ApplyLauncherWakeupAtCommit();
if (enabled)
ApplyLauncherWakeupAtCommit();
ObjectAddressSet(myself, SubscriptionRelationId, subid);