Re: TerminateOtherDBBackends code comments inconsistency.

2024-05-16 Thread Noah Misch
On Tue, Apr 30, 2024 at 09:10:52AM +0530, Amit Kapila wrote: > On Tue, Apr 30, 2024 at 2:58 AM Noah Misch wrote: > > On Mon, Apr 29, 2024 at 10:18:35AM +0530, Amit Kapila wrote: > > > 3a9b18b309 didn't change the docs of pg_terminate_backend and whatever > > > is mentioned w.r.t permissions in

Re: TerminateOtherDBBackends code comments inconsistency.

2024-05-06 Thread Amit Kapila
On Tue, Apr 30, 2024 at 10:36 PM Noah Misch wrote: > > > > > > One could argue the function should also check > > > isBackgroundWorker and ignore even bgworkers that set proc->roleId, but > > > I've > > > not done that. > > > > What is the argument for ignoring such workers? > > One of the

Re: TerminateOtherDBBackends code comments inconsistency.

2024-04-30 Thread Noah Misch
On Tue, Apr 30, 2024 at 09:10:52AM +0530, Amit Kapila wrote: > On Tue, Apr 30, 2024 at 2:58 AM Noah Misch wrote: > > On Mon, Apr 29, 2024 at 10:18:35AM +0530, Amit Kapila wrote: > > > On Mon, Apr 22, 2024 at 9:56 PM Noah Misch wrote: > > > > > 3a9b18b309 didn't change the docs of

Re: TerminateOtherDBBackends code comments inconsistency.

2024-04-29 Thread Amit Kapila
On Tue, Apr 30, 2024 at 2:58 AM Noah Misch wrote: > > On Mon, Apr 29, 2024 at 10:18:35AM +0530, Amit Kapila wrote: > > On Mon, Apr 22, 2024 at 9:56 PM Noah Misch wrote: > > > 3a9b18b309 didn't change the docs of pg_terminate_backend and whatever > > is mentioned w.r.t permissions in the doc of

Re: TerminateOtherDBBackends code comments inconsistency.

2024-04-29 Thread Noah Misch
On Mon, Apr 29, 2024 at 10:18:35AM +0530, Amit Kapila wrote: > On Mon, Apr 22, 2024 at 9:56 PM Noah Misch wrote: > > > > On Mon, Apr 15, 2024 at 11:17:54AM +0530, Amit Kapila wrote: > > > On Thu, Apr 11, 2024 at 6:58 PM Kirill Reshke > > > wrote: > > > > > > > > While working on [0] i have

Re: TerminateOtherDBBackends code comments inconsistency.

2024-04-28 Thread Amit Kapila
On Mon, Apr 22, 2024 at 9:56 PM Noah Misch wrote: > > On Mon, Apr 15, 2024 at 11:17:54AM +0530, Amit Kapila wrote: > > On Thu, Apr 11, 2024 at 6:58 PM Kirill Reshke > > wrote: > > > > > > While working on [0] i have noticed this comment in > > > TerminateOtherDBBackends function: > > > > > > /*

Re: TerminateOtherDBBackends code comments inconsistency.

2024-04-22 Thread Noah Misch
On Mon, Apr 15, 2024 at 11:17:54AM +0530, Amit Kapila wrote: > On Thu, Apr 11, 2024 at 6:58 PM Kirill Reshke wrote: > > > > While working on [0] i have noticed this comment in > > TerminateOtherDBBackends function: > > > > /* > > * Check whether we have the necessary rights to terminate other > >

Re: TerminateOtherDBBackends code comments inconsistency.

2024-04-15 Thread vignesh C
On Mon, 15 Apr 2024 at 11:18, Amit Kapila wrote: > > On Thu, Apr 11, 2024 at 6:58 PM Kirill Reshke wrote: > > > > While working on [0] i have noticed this comment in > > TerminateOtherDBBackends function: > > > > /* > > * Check whether we have the necessary rights to terminate other > > *

Re: TerminateOtherDBBackends code comments inconsistency.

2024-04-14 Thread Amit Kapila
On Thu, Apr 11, 2024 at 6:58 PM Kirill Reshke wrote: > > While working on [0] i have noticed this comment in > TerminateOtherDBBackends function: > > /* > * Check whether we have the necessary rights to terminate other > * sessions. We don't terminate any session until we ensure that we > * have

TerminateOtherDBBackends code comments inconsistency.

2024-04-11 Thread Kirill Reshke
Hi hackers! While working on [0] i have noticed this comment in TerminateOtherDBBackends function: /* * Check whether we have the necessary rights to terminate other * sessions. We don't terminate any session until we ensure that we * have rights on all the sessions to be terminated. These