Обсуждение: pgsql-server: Rearrange order of operations in heap_drop_with_catalog

Поиск
Список
Период
Сортировка

pgsql-server: Rearrange order of operations in heap_drop_with_catalog

От
tgl@svr1.postgresql.org (Tom Lane)
Дата:
Log Message:
-----------
Rearrange order of operations in heap_drop_with_catalog and index_drop
so that we close and flush the doomed relation's relcache entry before
we start to delete the underlying catalog rows, rather than afterwards.
For awhile yesterday I thought that an unexpected relcache entry rebuild
partway through this sequence might explain the infrequent parallel
regression failures we were chasing.  It doesn't, mainly because there's
no CommandCounterIncrement in the sequence and so the deletions aren't
"really" done yet.  But it sure seems like trouble waiting to happen.

Modified Files:
--------------
    pgsql-server/src/backend/catalog:
        heap.c (r1.272 -> r1.273)
        (http://developer.postgresql.org/cvsweb.cgi/pgsql-server/src/backend/catalog/heap.c.diff?r1=1.272&r2=1.273)
        index.c (r1.235 -> r1.236)
        (http://developer.postgresql.org/cvsweb.cgi/pgsql-server/src/backend/catalog/index.c.diff?r1=1.235&r2=1.236)
    pgsql-server/src/backend/commands:
        tablecmds.c (r1.126 -> r1.127)

(http://developer.postgresql.org/cvsweb.cgi/pgsql-server/src/backend/commands/tablecmds.c.diff?r1=1.126&r2=1.127)
    pgsql-server/src/include/catalog:
        heap.h (r1.68 -> r1.69)
        (http://developer.postgresql.org/cvsweb.cgi/pgsql-server/src/include/catalog/heap.h.diff?r1=1.68&r2=1.69)