Avoid creating parallel apply state hash table unless required. This hash table is used to cache the state of streaming transactions being applied by the parallel apply workers. So, this should be created only when we are successful in launching at least one worker. This avoids rare case memory leak when we are never able to launch any worker.
Author: Ted Yu Discussion: https://postgr.es/m/CALte62wg0rBR3Vj2beV=HiWo2qG9L0hzKcX=yulner0wmf4...@mail.gmail.com Branch ------ master Details ------- https://git.postgresql.org/pg/commitdiff/dca8b01f5f1f7c83c59a16393724fbd8a29ddecb Modified Files -------------- src/backend/replication/logical/applyparallelworker.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-)
