| From: | Michael Paquier <michael(at)paquier(dot)xyz> | 
|---|---|
| To: | pgsql-committers(at)lists(dot)postgresql(dot)org | 
| Subject: | pgsql: Add indisreplident to fields refreshed by RelationReloadIndexInf | 
| Date: | 2023-07-14 02:16:48 | 
| Message-ID: | E1qK8MS-000G5i-9A@gemulon.postgresql.org | 
| Views: | Whole Thread | Raw Message | Download mbox | Resend email | 
| Thread: | |
| Lists: | pgsql-committers | 
Add indisreplident to fields refreshed by RelationReloadIndexInfo()
RelationReloadIndexInfo() is a fast-path used for index reloads in the
relation cache, and it has always forgotten about updating
indisreplident, which is something that would happen after an index is
selected for a replica identity.  This can lead to incorrect cache
information provided when executing a command in a transaction context
that updates indisreplident.
None of the code paths currently on HEAD that need to check upon
pg_index.indisreplident fetch its value from the relation cache, always
relying on a fresh copy on the syscache.  Unfortunately, this may not be
the case of out-of-core code, that could see out-of-date value.
Author: Shruthi Gowda
Reviewed-by: Robert Haas, Dilip Kumar, Michael Paquier
Discussion: https://postgr.es/m/CAASxf_PBcxax0wW-3gErUyftZ0XrCs3Lrpuhq4-Z3Fak1DoW7Q@mail.gmail.com
Backpatch-through: 11
Branch
------
master
Details
-------
https://git.postgresql.org/pg/commitdiff/a5ea825f958c2de9fadb825cbf16bf9b1360f0df
Modified Files
--------------
src/backend/utils/cache/relcache.c | 1 +
1 file changed, 1 insertion(+)
| From | Date | Subject | |
|---|---|---|---|
| Next Message | Amit Kapila | 2023-07-14 03:09:10 | pgsql: Allow the use of a hash index on the subscriber during replicati | 
| Previous Message | Michael Paquier | 2023-07-14 01:14:11 | pgsql: Fix updates of indisvalid for partitioned indexes |