Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtp (Exim 4.84_2) (envelope-from ) id 1aj7l6-00059C-II for pgsql-hackers@arkaria.postgresql.org; Thu, 24 Mar 2016 16:05:16 +0000 Received: from localhost ([127.0.0.1] helo=postgresql.org) by malur.postgresql.org with smtp (Exim 4.84_2) (envelope-from ) id 1aj7l6-0001jS-0a for pgsql-hackers@arkaria.postgresql.org; Thu, 24 Mar 2016 16:05:16 +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 1aj7jl-0000Bt-Gq for pgsql-hackers@postgresql.org; Thu, 24 Mar 2016 16:03:53 +0000 Received: from sss.pgh.pa.us ([66.207.139.130]) by makus.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA384:256) (Exim 4.84_2) (envelope-from ) id 1aj7je-0000uW-Gj for pgsql-hackers@postgresql.org; Thu, 24 Mar 2016 16:03:52 +0000 Received: from sss1.sss.pgh.pa.us (localhost [127.0.0.1]) by sss.pgh.pa.us (8.14.4/8.14.4) with ESMTP id u2OG3dcL003578; Thu, 24 Mar 2016 12:03:39 -0400 From: Tom Lane To: Robert Haas cc: Kyotaro HORIGUCHI , Oskari Saarenmaa , "pgsql-hackers@postgresql.org" Subject: Re: Show dropped users' backends in pg_stat_activity In-reply-to: References: <56E87CD8.60007@ohmu.fi> <16068.1458143290@sss.pgh.pa.us> <20160323.123541.203539504.horiguchi.kyotaro@lab.ntt.co.jp> Comments: In-reply-to Robert Haas message dated "Thu, 24 Mar 2016 11:54:44 -0400" Date: Thu, 24 Mar 2016 12:03:39 -0400 Message-ID: <3577.1458835419@sss.pgh.pa.us> X-Pg-Spam-Score: -1.9 (-) 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 Robert Haas writes: > I am not really in favor of half-fixing this. If we can't > conveniently wait until a dropped role is completely out of the > system, then I don't see a lot of point in trying to do it in the > limited cases where we can. If LEFT JOIN is the way to go, then, > blech, but, so be it. I concur. Let's put the left join(s) into those views and call it good. BTW, I think we would need the left joins even if we had interlocking in DROP, just to protect ourselves against race conditions. Remember that what pg_stat_activity shows is a snapshot, which might be more or less out of date compared to the catalog contents. regards, tom lane -- Sent via pgsql-hackers mailing list (pgsql-hackers@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-hackers