projects
/
postgresql.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
fc749bc
)
Ensure unlinking of old index file with REINDEX (TABLESPACE)
author
Michael Paquier
<
[email protected]
>
Thu, 4 Feb 2021 08:16:47 +0000
(17:16 +0900)
committer
Michael Paquier
<
[email protected]
>
Thu, 4 Feb 2021 08:16:47 +0000
(17:16 +0900)
The original versions of the patch included this part, but a mismerge
from my side has made this piece go missing. Oversight in
c5b28604
.
src/backend/catalog/index.c
patch
|
blob
|
blame
|
history
diff --git
a/src/backend/catalog/index.c
b/src/backend/catalog/index.c
index 5a70fe4d2c4bdf7067d857aa86b0297f3faed718..1cb9172a5f31d310265ff4fe8b68d1277545de32 100644
(file)
--- a/
src/backend/catalog/index.c
+++ b/
src/backend/catalog/index.c
@@
-3712,6
+3712,12
@@
reindex_index(Oid indexId, bool skip_constraint_checks, char persistence,
{
/* Update its pg_class row */
SetRelationTableSpace(iRel, params->tablespaceOid, InvalidOid);
+
+ /*
+ * Schedule unlinking of the old index storage at transaction
+ * commit.
+ */
+ RelationDropStorage(iRel);
RelationAssumeNewRelfilenode(iRel);
/* Make sure the reltablespace change is visible */