Re: rare avl shutdown slowness (related to signal handling)
От | Qingqing Zhou |
---|---|
Тема | Re: rare avl shutdown slowness (related to signal handling) |
Дата | |
Msg-id | CAJjS0u3Rq=5M0cMmVHJ8v=pxfCQncRn7bRVgcfMmi4Hpwa9tDw@mail.gmail.com обсуждение исходный текст |
Ответ на | Re: rare avl shutdown slowness (related to signal handling) (Tom Lane <tgl@sss.pgh.pa.us>) |
Ответы |
Re: rare avl shutdown slowness (related to signal handling)
|
Список | pgsql-hackers |
On Tue, Apr 7, 2015 at 2:32 PM, Tom Lane <tgl@sss.pgh.pa.us> wrote: > That seems like (a) a hack, and (b) not likely to solve the problem > completely, unless you leave interrupts held throughout proc_exit(), > which would create all sorts of opportunities for corner case bugs > during on_proc_exit hooks. > Hmm, looks like proc_exit() already taken care of this by setting proc_exit_inprogress and StatementCancelHandler() respects it. Actually, in quickdie(), I found a similar practice for the same reason: /* * Prevent interrupts while exiting; though we just blocked signals that * would queue new interrupts, one may have beenpending. We don't want a * quickdie() downgraded to a mere query cancel. */HOLD_INTERRUPTS(); I do feel that we have too many functions instructing how to handle interrupts and they are subtle - I just found a new friend HOLD_CANCEL_INTERRUPTS :-( Regards, Qingqing
В списке pgsql-hackers по дате отправления: