Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtp (Exim 4.84_2) (envelope-from ) id 1bFlbe-0001l3-O1 for pgsql-bugs@arkaria.postgresql.org; Wed, 22 Jun 2016 17:06:26 +0000 Received: from localhost ([127.0.0.1] helo=postgresql.org) by malur.postgresql.org with smtp (Exim 4.84_2) (envelope-from ) id 1bFlbd-00069a-SS for pgsql-bugs@arkaria.postgresql.org; Wed, 22 Jun 2016 17:06:25 +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 1bFlaz-0005DX-Mu for pgsql-bugs@postgresql.org; Wed, 22 Jun 2016 17:05:45 +0000 Received: from mail-qk0-x231.google.com ([2607:f8b0:400d:c09::231]) by makus.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA1:256) (Exim 4.84_2) (envelope-from ) id 1bFlaw-0004x9-Tw for pgsql-bugs@postgresql.org; Wed, 22 Jun 2016 17:05:44 +0000 Received: by mail-qk0-x231.google.com with SMTP id t127so73627872qkf.1 for ; Wed, 22 Jun 2016 10:05:42 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=2ndquadrant-com.20150623.gappssmtp.com; s=20150623; h=subject:to:references:cc:from:message-id:date:user-agent :mime-version:in-reply-to:content-transfer-encoding; bh=JVSxA1GN6agPrNmgc7OJtBPQ4t0wEDjN8Y1c52F2syo=; b=vCSyJXzAqbhKP5YIorffP8THlYyFie1ZFo98l7kv/r69iiN9ltInMtZcBXFKBqLewa t94e6gkNylUDBVXM90y4tla9RfgO7aDPceh11S5hXxugn5LWVoGTSvWkbyIqLGT04PgF Ts4Kt6HNNryLyJKmnotEcaNoj54NcT+3S0/madNn5dCUaIQXecgJYqLJjorKx0R2/ID/ dZxyKyLxybHAE2O44mzl8FkO9XhWyQEq5FdmJ8LrYi0XCYLJtT5pdUksvZZV/TSvG3/+ X3X5WIRLepDtmzG2g7DisLug8tXNil3w1yIp/i3MKcLyg1ovJdGqy8bSBV66wgwISC0B UeyA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:subject:to:references:cc:from:message-id:date :user-agent:mime-version:in-reply-to:content-transfer-encoding; bh=JVSxA1GN6agPrNmgc7OJtBPQ4t0wEDjN8Y1c52F2syo=; b=dcg/PUy1ugQQ/L/7FJxxICIKruGVTTCpByRb5eXPrHKH+zYk1Z0b6rXRL3wL6/A41K PrQn8nEyNFJNgSC8URifffWj6YR/Fwe2TfhVznneiTedIhIfwk4eImfCS5YhCj6Spb6T a4egmOOFuAqkGPoLbCbPTlg6CPrL/0Wf7GEWg5q0U3HFRXbQmMpjCVxFyDncNoOJCkX0 esgLSZSrL0tFSyquw4w5YfZPSr/kIwNTJ/TUi3mSkbmJjX3Dg2qDDrkr+crWLc34RjLu BmRX7NOL6ZvzStLobTLgg6h3WBcpQv82JFH3/TTWePbzCPIKn7RH9tsqvFpefebTceLk avlw== X-Gm-Message-State: ALyK8tKun9pkqopV+jLphAct2iFi3dzAc/51HN0Vu7MzhvIOedboiZNK05jNhjzXjh+APeRvoqjWCrxBRsiFbp95lIjSLKjyn6M2DT9bS0C1400iB/L3IOlingYBXiFZmK3W/XdMldKDRdfC0csmqKMGT8uHxXSdRGFa7ZEtNA+LJgcspqr+kGCqK9FwEdje X-Received: by 10.55.135.7 with SMTP id j7mr39718490qkd.178.1466615141386; Wed, 22 Jun 2016 10:05:41 -0700 (PDT) Received: from alderaan.marques ([181.91.209.212]) by smtp.googlemail.com with ESMTPSA id a83sm381999qkb.11.2016.06.22.10.05.39 (version=TLSv1/SSLv3 cipher=OTHER); Wed, 22 Jun 2016 10:05:40 -0700 (PDT) Subject: Re: pg_dump doesn't dump new objects created in schemas from extensions To: Tom Lane , Stephen Frost References: <409fe594-f4cc-89f5-c0d2-0a921987a864@2ndquadrant.com> <20160616185547.GA72247@alvherre.pgsql> <24a4d9cf-025d-d855-fe76-3af3f878174d@2ndquadrant.com> <29478.1466605967@sss.pgh.pa.us> <20160622145349.GK21416@tamriel.snowman.net> <30842.1466608326@sss.pgh.pa.us> Cc: Michael Paquier , Alvaro Herrera , PostgreSQL mailing lists From: =?UTF-8?Q?Mart=c3=adn_Marqu=c3=a9s?= Message-ID: Date: Wed, 22 Jun 2016 14:05:32 -0300 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:45.0) Gecko/20100101 Thunderbird/45.1.1 MIME-Version: 1.0 In-Reply-To: <30842.1466608326@sss.pgh.pa.us> Content-Type: text/plain; charset=windows-1252 Content-Transfer-Encoding: 8bit X-Pg-Spam-Score: -2.6 (--) List-Archive: List-Help: List-ID: List-Owner: List-Post: List-Subscribe: List-Unsubscribe: X-Mailing-List: pgsql-bugs Precedence: bulk Sender: pgsql-bugs-owner@postgresql.org El 22/06/16 a las 12:12, Tom Lane escribió: > > Ah. So maybe we just need to rearrange selectDumpableNamespace. > Offhand, it seems like we want checkExtensionMembership to adjust the > namespace's dump bits, but not its dump_contained bits (which indeed it > already doesn't, which until just now I would have said is an oversight). On HEAD I actually see that we *are* setting dump_contains as well: if (fout->remoteVersion < 90600) dobj->dump = DUMP_COMPONENT_NONE; else dobj->dump = ext->dobj.dump_contains & (DUMP_COMPONENT_ACL | DUMP_COMPONENT_SECLABEL | DUMP_COMPONENT_POLICY); > So maybe just moving the checkExtensionMembership call to after the other > stuff would be enough in HEAD? Looking into older versions as well I can't see how placing checkExtensionMembership at the end of selectDumpableNamespace would help. (like-wise for other selectDumpable's) If a non extension table belongs to a schema created by an extension, the schema will have nsinfo->dobj.dump = false, so when we check if the non extension table is dumpable we end up with this (unless there's -t or -T which is not interesting for this patch): tbinfo->dobj.dump = tbinfo->dobj.namespace->dobj.dump; On HEAD (where I started looking at this bug) the situation is similar. It might just be that I'm missing something here. Regards, -- Martín Marqués http://www.2ndQuadrant.com/ PostgreSQL Development, 24x7 Support, Training & Services -- Sent via pgsql-bugs mailing list (pgsql-bugs@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-bugs