git.postgresql.org Git - postgresql.git/commit

git projects / postgresql.git / commit
? search:
summary | shortlog | log | commit | commitdiff | tree
(parent: d9bb719) | patch
Don't shut down Gather[Merge] early under Limit.
2019年11月18日 08:47:41 +0000 (14:17 +0530)
2019年11月26日 03:37:35 +0000 (09:07 +0530)
commit d0ccfa9d6a3da0a47ee02947f54dd36f9f90972c
Don't shut down Gather[Merge] early under Limit.

Revert part of commit 19df1702f5.

Early shutdown was added by that commit so that we could collect
statistics from workers, but unfortunately, it interacted badly with
rescans. The problem is that we ended up destroying the parallel context
which is required for rescans. This leads to rescans of a Limit node over
a Gather node to produce unpredictable results as it tries to access
destroyed parallel context. By reverting the early shutdown code, we
might lose statistics in some cases of Limit over Gather [Merge], but that
will require further study to fix.

Reported-by: Jerry Sievers
Diagnosed-by: Thomas Munro
Author: Amit Kapila, testcase by Vignesh C
Backpatch-through: 9.6
Discussion: https://postgr.es/m/87ims2amh6.fsf@jsievers.enova.com
src/backend/executor/nodeLimit.c diff | blob | blame | history
src/test/regress/expected/select_parallel.out diff | blob | blame | history
src/test/regress/sql/select_parallel.sql diff | blob | blame | history
This is the main PostgreSQL git repository.
RSS Atom

AltStyle によって変換されたページ (->オリジナル) /