Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtp (Exim 4.84_2) (envelope-from ) id 1dsJ3M-0004bP-Ax for pgsql-hackers@arkaria.postgresql.org; Thu, 14 Sep 2017 01:34:52 +0000 Received: from localhost ([127.0.0.1] helo=postgresql.org) by malur.postgresql.org with smtp (Exim 4.84_2) (envelope-from ) id 1dsJ3L-0002oz-QK for pgsql-hackers@arkaria.postgresql.org; Thu, 14 Sep 2017 01:34:51 +0000 Received: from makus.postgresql.org ([2001:4800:1501:1::229]) by malur.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA384:256) (Exim 4.84_2) (envelope-from ) id 1dsJ1o-0008PL-5P for pgsql-hackers@postgresql.org; Thu, 14 Sep 2017 01:33:16 +0000 Received: from out3-smtp.messagingengine.com ([66.111.4.27]) by makus.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA384:256) (Exim 4.84_2) (envelope-from ) id 1dsJ1l-0001Ii-1q for pgsql-hackers@postgresql.org; Thu, 14 Sep 2017 01:33:14 +0000 Received: from compute7.internal (compute7.nyi.internal [10.202.2.47]) by mailout.nyi.internal (Postfix) with ESMTP id 652D420AEB; Wed, 13 Sep 2017 21:33:11 -0400 (EDT) Received: from frontend2 ([10.202.2.161]) by compute7.internal (MEProxy); Wed, 13 Sep 2017 21:33:11 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d= messagingengine.com; h=cc:content-transfer-encoding:content-type :date:from:in-reply-to:message-id:mime-version:references :subject:to:x-me-sender:x-me-sender:x-sasl-enc:x-sasl-enc; s= fm1; bh=8OEuKuoMFu9mC1ADbWULD1GszicvVr/sxsquQZCj8Zw=; b=Jjj2nUqz 5OfhtBVG5v4/U3wPQKhaJ0a8oIBoUCb331pZVI+kLiEAd0pVlY/v7Pc1gSaiI/R7 cKrBmxna8gWwYvVgkCHmlwLBBafcTeVXRAuC4bSTHiAV/dUNZnNlACSSkCpVv6if Y/KObbqWb/wcEcZNGDhc/AvI53EdxlHkKjk7qO+v74wjSLb3n/eVg7RcGoDkeazg RLIVMLqTbgnEAoa611z/kDci/EOZVmfndRO9P+ZfmPaRlc7kEu95cvFzeekvp/wg U1/hKrFZBRgfcmlXHlZYo588wAYR2TJnn9LzY+pL4JyEUIdRxu9zCR5rGqRe7RmO tRURnQgSwKUMcQ== X-ME-Sender: X-Sasl-enc: HXtJc/ATbFHjXvR8XT06Yy0e6ZwN8aLK3KGCa3aaHko8 1505352791 Received: from april.local (c-73-13-66-39.hsd1.pa.comcast.net [73.13.66.39]) by mail.messagingengine.com (Postfix) with ESMTPA id B6AAE24081; Wed, 13 Sep 2017 21:33:10 -0400 (EDT) Subject: Re: DROP SUBSCRIPTION hangs if sub is disabled in the same transaction To: Alvaro Herrera , Tom Lane References: <20170913135615.sxhwjp7bbo7bnq5g@alvherre.pgsql> Cc: Arseny Sher , pgsql-hackers@postgresql.org From: Peter Eisentraut Organization: 2ndQuadrant Message-ID: Date: Wed, 13 Sep 2017 21:33:09 -0400 User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.12; rv:52.0) Gecko/20100101 Thunderbird/52.3.0 MIME-Version: 1.0 In-Reply-To: <20170913135615.sxhwjp7bbo7bnq5g@alvherre.pgsql> Content-Type: text/plain; charset=utf-8 Content-Language: en-US Content-Transfer-Encoding: 7bit List-Archive: List-Help: List-ID: List-Owner: List-Post: List-Subscribe: List-Unsubscribe: X-Mailing-List: pgsql-hackers Precedence: bulk Sender: pgsql-hackers-owner@postgresql.org On 9/13/17 09:56, Alvaro Herrera wrote: > Tom Lane wrote: >> Peter Eisentraut writes: > >>> - Disallow DROP SUBSCRIPTION in a transaction under certain >>> circumstances, for example if a transaction has previously manipulated >>> the same subscription. > >> ISTM the second of those (refuse to drop an in-use subscription) is >> by far the least surprising behavior. > > +1 for that option. IIRC this has precedent for other object types such > as tables, where we refuse some action if we have already operated on > the table in the same transaction. What are some examples of such behavior? -- Peter Eisentraut http://www.2ndQuadrant.com/ PostgreSQL Development, 24x7 Support, Remote DBA, Training & Services -- Sent via pgsql-hackers mailing list (pgsql-hackers@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-hackers