aboutsummaryrefslogtreecommitdiff
path: root/src/backend/utils/adt/array_userfuncs.c
diff options
context:
space:
mode:
authorTom Lane <tgl@sss.pgh.pa.us>2012-03-12 16:10:05 -0400
committerTom Lane <tgl@sss.pgh.pa.us>2012-03-12 16:10:28 -0400
commitb4af1c25bbc636379efc5d2ffb9d420765705b8a (patch)
treebba47fb7ba13464c966e2ddd21f6f1f5398faa3d /src/backend/utils/adt/array_userfuncs.c
parentbad250f4f31704f05247fa4696ac2077f884ed8e (diff)
downloadpostgresql-b4af1c25bbc636379efc5d2ffb9d420765705b8a.tar.gz
postgresql-b4af1c25bbc636379efc5d2ffb9d420765705b8a.zip
Fix SPGiST vacuum algorithm to handle concurrent tuple motion properly.
A leaf tuple that we need to delete could get moved as a consequence of an insertion happening concurrently with the VACUUM scan. If it moves from a page past the current scan point to a page before, we'll miss it, which is not acceptable. Hence, when we see a leaf-page REDIRECT that could have been made since our scan started, chase down the redirection pointer much as if we were doing a normal index search, and be sure to vacuum every page it leads to. This fixes the issue because, if the tuple was on page N at the instant we start our scan, we will surely find it as a consequence of chasing the redirect from page N, no matter how much it moves around in between. Problem noted by Takashi Yamamoto.
Diffstat (limited to 'src/backend/utils/adt/array_userfuncs.c')
0 files changed, 0 insertions, 0 deletions