aboutsummaryrefslogtreecommitdiff
path: root/src/backend/executor
diff options
context:
space:
mode:
authorTomas Vondra <tomas.vondra@postgresql.org>2022-03-17 17:03:45 +0100
committerTomas Vondra <tomas.vondra@postgresql.org>2022-03-17 17:03:48 +0100
commit5a079662256e381fde699c4fbbed6c2504a6d30a (patch)
tree70bd035b005499f834f4bf071118e881f708559b /src/backend/executor
parenta9b7e92084cdea1bd397ec26c3233206932f29c7 (diff)
downloadpostgresql-5a079662256e381fde699c4fbbed6c2504a6d30a.tar.gz
postgresql-5a079662256e381fde699c4fbbed6c2504a6d30a.zip
Fix row filters with multiple publications
When publishing changes through a artition root, we should use the row filter for the top-most ancestor. The relation may be added to multiple publications, using different ancestors, and 52e4f0cd47 handled this incorrectly. With c91f71b9dc we find the correct top-most ancestor, but the code tried to fetch the row filter from all publications, including those using a different ancestor etc. No row filter can be found for such publications, which was treated as replicating all rows. Similarly to c91f71b9dc, this seems to be a rare issue in practice. It requires multiple publications including the same partitioned relation, through different ancestors. Fixed by only passing publications containing the top-most ancestor to pgoutput_row_filter_init(), so that treating a missing row filter as replicating all rows is correct. Report and fix by me, test case by Hou zj. Reviews and improvements by Amit Kapila. Author: Tomas Vondra, Hou zj, Amit Kapila Reviewed-by: Amit Kapila, Hou zj Discussion: https://postgr.es/m/d26d24dd-2fab-3c48-0162-2b7f84a9c893%40enterprisedb.com
Diffstat (limited to 'src/backend/executor')
0 files changed, 0 insertions, 0 deletions