Received: from maia.hub.org (unknown [200.46.204.183]) by mail.postgresql.org (Postfix) with ESMTP id 8CA6E6334ED for ; Mon, 21 Dec 2009 04:14:24 -0400 (AST) Received: from mail.postgresql.org ([200.46.204.86]) by maia.hub.org (mx1.hub.org [200.46.204.183]) (amavisd-maia, port 10024) with ESMTP id 59926-03-7 for ; Mon, 21 Dec 2009 08:14:17 +0000 (UTC) X-Greylist: from auto-whitelisted by SQLgrey-1.7.6 Received: from outmail128113.authsmtp.net (outmail128113.authsmtp.net [62.13.128.113]) by mail.postgresql.org (Postfix) with ESMTP id D770B6337C2 for ; Mon, 21 Dec 2009 03:46:43 -0400 (AST) Received: from mail-c194.authsmtp.com (mail-c194.authsmtp.com [62.13.128.121]) by punt4.authsmtp.com (8.14.2/8.14.2/Kp) with ESMTP id nBL7kf5P018775; Mon, 21 Dec 2009 07:46:41 GMT Received: from [192.168.0.3] (88-110-223-66.dynamic.dsl.as9105.com [88.110.223.66]) (authenticated bits=0) by mail.authsmtp.com (8.14.2/8.14.2/Kp) with ESMTP id nBL7kdjW036990; Mon, 21 Dec 2009 07:46:40 GMT Subject: Re: Small Bug in GetConflictingVirtualXIDs From: Simon Riggs To: Andres Freund Cc: pgsql-hackers@postgresql.org In-Reply-To: <200912210402.37850.andres@anarazel.de> References: <200912210402.37850.andres@anarazel.de> Content-Type: text/plain Date: Mon, 21 Dec 2009 07:46:39 +0000 Message-Id: <1261381599.17644.1803.camel@ebony> Mime-Version: 1.0 X-Mailer: Evolution 2.26.1 Content-Transfer-Encoding: 7bit X-Server-Quench: f9af4588-ee04-11de-80b9-0022640b883e X-Report-Spam: If SPAM / abuse - report it at: http://www.authsmtp.com/abuse X-AuthRoute: OCdxZQATClZOTQEd DAteCiN5VAwpPBRK HVkIKg5MJUcNSQVJ NksadBtFagRbaVxS HGQLW11EUFp7XWV/ bwofZQ1DY0tOQQdo U1ZPRE1XHAJ3AVJf dGIZCU0oEAVFfnd5 ZQhgX3FTEhJzJBB5 R0ZcCDhTZWN9aWFL BV1Qd1FdbQNKfB1D blAtXHsONCtlM3Bw JAo6OzR5FyhQYCVT Ci4AMXkVR0gPHzUg RhYNIzQ1AVAMQxUS AwdO X-Authentic-SMTP: 61633235383639.1015:706/Kp X-AuthFastPath: 255 X-Virus-Status: No virus detected - but ensure you scan with your own anti-virus system. X-Virus-Scanned: Maia Mailguard 1.0.1 X-Spam-Status: No, hits=-2.599 tagged_above=-10 required=5 tests=BAYES_00=-2.599 X-Spam-Level: X-Archive-Number: 200912/1833 X-Sequence-Number: 152536 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 reduce the number of backends that would conflict, so it looks like I broke that case when I did that. > Should easily be solvable through an extra parameter for > GetConflictingVirtualXIDs. Want me to prepare a patch? Much appreciated, thanks. -- Simon Riggs www.2ndQuadrant.com