Re: pg_terminate_backend for same-role
| От | Fujii Masao | 
|---|---|
| Тема | Re: pg_terminate_backend for same-role | 
| Дата | |
| Msg-id | CAHGQGwEFU7mdoyBDPJ-zNo2cX4VMXqXVxDVdkOLZozJmpE2zPg@mail.gmail.com обсуждение исходный текст  | 
		
| Ответ на | pg_terminate_backend for same-role (Daniel Farina <daniel@heroku.com>) | 
| Ответы | 
                	
            		Re: pg_terminate_backend for same-role
            		
            		 Re: pg_terminate_backend for same-role  | 
		
| Список | pgsql-hackers | 
On Fri, Mar 16, 2012 at 8:14 AM, Daniel Farina <daniel@heroku.com> wrote: > Parallel to pg_cancel_backend, it'd be nice to allow the user to just > outright kill a backend that they own (politely, with a SIGTERM), > aborting any transactions in progress, including the idle transaction, > and closing the socket. +1 > I imagine the problem is a race condition whereby a pid might be > reused by another process owned by another user (doesn't that also > affect pg_cancel_backend?). Yes, but I think it's too unlikely to happen. Not sure if we really should worry about that. > Shall we just do everything using the > MyCancelKey (which I think could just be called "SessionKey", > "SessionSecret", or even just "Session") as to ensure we have no case > of mistaken identity? Or does that end up being problematic? What if pid is unfortunately reused after passing the test of MyCancelKey and before sending the signal? Regards, -- Fujii Masao NIPPON TELEGRAPH AND TELEPHONE CORPORATION NTT Open Source Software Center
В списке pgsql-hackers по дате отправления: