Re: [HACKERS] Small Bug in GetConflictingVirtualXIDs

2010-01-14 Thread Simon Riggs
On Sun, 2009-12-27 at 20:11 +0100, Andres Freund wrote: > On Tuesday 22 December 2009 11:42:30 Simon Riggs wrote: > > On Tue, 2009-12-22 at 03:19 +0100, Andres Freund wrote: > > > On Monday 21 December 2009 16:48:52 Simon Riggs wrote: > > > > Giving the drop database a snapshot is not the answer. I

Re: [HACKERS] Small Bug in GetConflictingVirtualXIDs

2010-01-10 Thread Simon Riggs
On Sun, 2009-12-27 at 20:11 +0100, Andres Freund wrote: > On Tuesday 22 December 2009 11:42:30 Simon Riggs wrote: > > On Tue, 2009-12-22 at 03:19 +0100, Andres Freund wrote: > > > On Monday 21 December 2009 16:48:52 Simon Riggs wrote: > > > > Giving the drop database a snapshot is not the answer. I

Re: [HACKERS] Small Bug in GetConflictingVirtualXIDs

2009-12-27 Thread Andres Freund
On Sunday 27 December 2009 21:04:43 Simon Riggs wrote: > On Sun, 2009-12-27 at 20:11 +0100, Andres Freund wrote: > > On Tuesday 22 December 2009 11:42:30 Simon Riggs wrote: > > > On Tue, 2009-12-22 at 03:19 +0100, Andres Freund wrote: > > > > On Monday 21 December 2009 16:48:52 Simon Riggs wrote: >

Re: [HACKERS] Small Bug in GetConflictingVirtualXIDs

2009-12-27 Thread Andres Freund
On Tuesday 22 December 2009 11:42:30 Simon Riggs wrote: > On Tue, 2009-12-22 at 03:19 +0100, Andres Freund wrote: > > On Monday 21 December 2009 16:48:52 Simon Riggs wrote: > > > Giving the drop database a snapshot is not the answer. I expect Andres > > > to be able to fix this with a simple patch

Re: [HACKERS] Small Bug in GetConflictingVirtualXIDs

2009-12-27 Thread Simon Riggs
On Sun, 2009-12-27 at 20:11 +0100, Andres Freund wrote: > On Tuesday 22 December 2009 11:42:30 Simon Riggs wrote: > > On Tue, 2009-12-22 at 03:19 +0100, Andres Freund wrote: > > > On Monday 21 December 2009 16:48:52 Simon Riggs wrote: > > > > Giving the drop database a snapshot is not the answer. I

Re: [HACKERS] Small Bug in GetConflictingVirtualXIDs

2009-12-22 Thread Andres Freund
On Tuesday 22 December 2009 11:42:30 Simon Riggs wrote: > On Tue, 2009-12-22 at 03:19 +0100, Andres Freund wrote: > > On Monday 21 December 2009 16:48:52 Simon Riggs wrote: > > > Giving the drop database a snapshot is not the answer. I expect Andres > > > to be able to fix this with a simple patch

Re: [HACKERS] Small Bug in GetConflictingVirtualXIDs

2009-12-22 Thread Simon Riggs
On Tue, 2009-12-22 at 03:19 +0100, Andres Freund wrote: > On Monday 21 December 2009 16:48:52 Simon Riggs wrote: > > Giving the drop database a snapshot is not the answer. I expect Andres > > to be able to fix this with a simple patch that would not effect the > > case of normal running. > Actually

Re: [HACKERS] Small Bug in GetConflictingVirtualXIDs

2009-12-21 Thread Andres Freund
On Monday 21 December 2009 16:48:52 Simon Riggs wrote: > Giving the drop database a snapshot is not the answer. I expect Andres > to be able to fix this with a simple patch that would not effect the > case of normal running. Actually its less simply than I had thought at first - I don't think the c

Re: [HACKERS] Small Bug in GetConflictingVirtualXIDs

2009-12-21 Thread Andres Freund
On Monday 21 December 2009 16:38:07 Tom Lane wrote: > Alvaro Herrera writes: > > Andres Freund wrote: > >> The logic behind this seems fine except in the case of dropping a > >> database. There you very well might have a open connection without an > >> open snapshot. > > Perhaps the simplest fix i

Re: [HACKERS] Small Bug in GetConflictingVirtualXIDs

2009-12-21 Thread Simon Riggs
On Mon, 2009-12-21 at 10:38 -0500, Tom Lane wrote: > Alvaro Herrera writes: > > Andres Freund wrote: > >> The logic behind this seems fine except in the case of dropping a > >> database. > >> There you very well might have a open connection without an open snapshot. > > > Perhaps the simplest f

Re: [HACKERS] Small Bug in GetConflictingVirtualXIDs

2009-12-21 Thread Tom Lane
Alvaro Herrera writes: > Andres Freund wrote: >> The logic behind this seems fine except in the case of dropping a database. >> There you very well might have a open connection without an open snapshot. > Perhaps the simplest fix is to ensure that drop database gets a snapshot? I confess to not

Re: [HACKERS] Small Bug in GetConflictingVirtualXIDs

2009-12-21 Thread Alvaro Herrera
Andres Freund wrote: > The logic behind this seems fine except in the case of dropping a database. > There you very well might have a open connection without an open snapshot. Perhaps the simplest fix is to ensure that drop database gets a snapshot? -- Alvaro Herrera

Re: [HACKERS] Small Bug in GetConflictingVirtualXIDs

2009-12-21 Thread Simon Riggs
On Mon, 2009-12-21 at 04:02 +0100, Andres Freund wrote: > The logic behind this seems fine except in the case of dropping a database. > There you very well might have a open connection without an open snapshot. Yes, you're right, thanks for the report. I re-arranged the logic there recently to

[HACKERS] Small Bug in GetConflictingVirtualXIDs

2009-12-20 Thread Andres Freund
Hi Simon, Hi all, HS currently does the following in GetConflictingVirtualXIDs TransactionId pxmin = proc->xmin; /* * We ignore an invalid pxmin because this means that backend * has no snapshot and cannot get another one while we hold exclusive lock. */ if (TransactionIdIsValid(pxmin) && !