Skip to content

Commit d1f8e7a

Browse files
committed
Remove obsolete commentary.
Since we got rid of non-MVCC catalog scans, the fourth reason given for using a non-transactional update in index_update_stats() is obsolete. The other three are still good, so we're not going to change the code, but fix the comment.
1 parent 3345ba4 commit d1f8e7a

File tree

1 file changed

+0
-8
lines changed

1 file changed

+0
-8
lines changed

src/backend/catalog/index.c

Lines changed: 0 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1783,14 +1783,6 @@ index_update_stats(Relation rel,
17831783
* trying to change the pg_class row to the same thing, so it doesn't
17841784
* matter which goes first).
17851785
*
1786-
* 4. Even with just a single CREATE INDEX, there's a risk factor because
1787-
* someone else might be trying to open the rel while we commit, and this
1788-
* creates a race condition as to whether he will see both or neither of
1789-
* the pg_class row versions as valid. Again, a non-transactional update
1790-
* avoids the risk. It is indeterminate which state of the row the other
1791-
* process will see, but it doesn't matter (if he's only taking
1792-
* AccessShareLock, then it's not critical that he see relhasindex true).
1793-
*
17941786
* It is safe to use a non-transactional update even though our
17951787
* transaction could still fail before committing. Setting relhasindex
17961788
* true is safe even if there are no indexes (VACUUM will eventually fix

0 commit comments

Comments
 (0)
pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy