aboutsummaryrefslogtreecommitdiff
path: root/src/backend/access/gist/gistproc.c
diff options
context:
space:
mode:
authorTom Lane <tgl@sss.pgh.pa.us>2012-07-26 14:29:37 -0400
committerTom Lane <tgl@sss.pgh.pa.us>2012-07-26 14:29:37 -0400
commit7a7d970b36845310281f6f5c4313bd49a110df44 (patch)
tree8ec4f6cc8d190c459bf320682629ec00d5d97ef1 /src/backend/access/gist/gistproc.c
parenta1195a5c26c316b46a6c4a8268116b6deeab2d72 (diff)
downloadpostgresql-7a7d970b36845310281f6f5c4313bd49a110df44.tar.gz
postgresql-7a7d970b36845310281f6f5c4313bd49a110df44.zip
Only allow autovacuum to be auto-canceled by a directly blocked process.
In the original coding of the autovacuum cancel feature, commit acac68b2bcae818bc8803b8cb8cbb17eee8d5e2b, an autovacuum process was considered a target for cancellation if it was found to hard-block any process examined in the deadlock search. This patch tightens the test so that the autovacuum must directly hard-block the current process. This should make the behavior more predictable in general, and in particular it ensures that an autovacuum will not be canceled with less than deadlock_timeout grace period. In the old coding, it was possible for an autovacuum to be canceled almost instantly, given unfortunate timing of two or more other processes' lock attempts. This also justifies the logging methodology in the recent commit d7318d43d891bd63e82dcfc27948113ed7b1db80; without this restriction, that patch isn't providing enough information to see the connection of the canceling process to the autovacuum. Like that one, patch all the way back.
Diffstat (limited to 'src/backend/access/gist/gistproc.c')
0 files changed, 0 insertions, 0 deletions