Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA1:256) (Exim 4.89) (envelope-from ) id 1gxF93-0003yt-Bd for pgsql-hackers@arkaria.postgresql.org; Fri, 22 Feb 2019 18:01:57 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.89) (envelope-from ) id 1gxF91-0001kS-JJ for pgsql-hackers@arkaria.postgresql.org; Fri, 22 Feb 2019 18:01:55 +0000 Received: from magus.postgresql.org ([2a02:c0:301:0:ffff::29]) by malur.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA1:256) (Exim 4.89) (envelope-from ) id 1gxF91-0001cF-5d for pgsql-hackers@lists.postgresql.org; Fri, 22 Feb 2019 18:01:55 +0000 Received: from mail-it1-x141.google.com ([2607:f8b0:4864:20::141]) by magus.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA1:256) (Exim 4.89) (envelope-from ) id 1gxF8y-0000Yb-86 for pgsql-hackers@postgresql.org; Fri, 22 Feb 2019 18:01:54 +0000 Received: by mail-it1-x141.google.com with SMTP id l66so4422868itg.3 for ; Fri, 22 Feb 2019 10:01:51 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=telsasoft-com.20150623.gappssmtp.com; s=20150623; h=date:from:to:cc:subject:message-id:references:mime-version :content-disposition:in-reply-to:user-agent; bh=NVx5GMrU15KZbdNQCnB6h/YZ90uaAXqTroPhHJ7Pc+s=; b=YkVQ68IB8Op2qPsA7IvKEoTDIUkXmQEk/2kWvH2mnI9Me/HaB1rhxvGZmhkcO2ERbH 4w/0Zvc4i7q9tgNlGpt4m8ICnJegjfyVPOqzNnX7xlok6nN5JPwo1Ut70QT3K7i6ClVq cXkKeESxQ8YpNsCx7bUZVPRkiMT4j0TW+nAy7NNQ838ayc56jQ5RyF9e3YTG7DeFxElj VECdHWiqqzvDAv2WFj5ZACzT9KOgB6k1iGxa8dCzT5b0s9HxDCB8QgUHAjScm3vbFAg7 xVaa5VZ6Sv5P0wuwjP5W58WcocYjo6FxvZL6tEh19O9QOMTyOFovIxXQxytGKDNdwyW4 aMaA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:date:from:to:cc:subject:message-id:references :mime-version:content-disposition:in-reply-to:user-agent; bh=NVx5GMrU15KZbdNQCnB6h/YZ90uaAXqTroPhHJ7Pc+s=; b=nHU0iq8MmjP2erCsQPOe9G0qGJPlN1qSYnlvUTGB8kUmi+QwrOV8g35Q+cSh/Mzq3a puyBk9gQ19KVVypIbTt8IcBxxYu/BED+LJaWaHFqtF0fGTmYo7Kx+UH1rXN82xo4JbjY iHf0dKVVPs/CFgfaUFAG7JoP74Dd0C6TwJe4AgmSuvfEuj2l7G7oOL/NHR8z1hOeaITa K/INRSHGQuN74af1YcJf7Vj1La7Pl9Lv35/2vDNNfA8Ml0fTK+VEDZGJzP0pVqoXF5Oe 05vD/PVSBLXGstEGOU5ayQuC3COKcg2INV9bq1GdMsyLQq5CGfTYgihBiy3OK1sPeT11 qmQA== X-Gm-Message-State: AHQUAubC2hRHOSQQ2SuvX8Wz5F8hysPdWwVPZk929m3xUUGsRxpCB0Hp gcDHCItYRt3YmaaY4LywgYhfqA== X-Google-Smtp-Source: AHgI3IY72I2KCT67HBcR5mJ75yopyzVqYk9vUSlMmdgoOdvIrM1MhPg6kf66x7c65irwIFtSGY/rJA== X-Received: by 2002:a24:cd87:: with SMTP id l129mr2802930itg.86.1550858509573; Fri, 22 Feb 2019 10:01:49 -0800 (PST) Received: from pryzbyj (charmander.telsasoft.com. [50.244.222.1]) by smtp.gmail.com with ESMTPSA id f13sm761420iol.82.2019.02.22.10.01.47 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Fri, 22 Feb 2019 10:01:48 -0800 (PST) Received: by pryzbyj (Postfix, from userid 1000) id E60B7800B9A; Fri, 22 Feb 2019 12:01:46 -0600 (CST) Date: Fri, 22 Feb 2019 12:01:46 -0600 From: Justin Pryzby To: Amit Langote Cc: Amit Langote , Tom Lane , David Rowley , "Imai, Yoshikazu" , Alvaro Herrera , Pg Hackers Subject: Re: speeding up planning with partitions Message-ID: <20190222180146.GH28750@telsasoft.com> References: <7453.1550518972@sss.pgh.pa.us> <0a70234e-b2e6-debc-2fb5-e8fd927caa00@lab.ntt.co.jp> <1002.1550596071@sss.pgh.pa.us> <30961.1550609873@sss.pgh.pa.us> <250c61bc-479c-92f4-d19d-d768e3bcdcbc@lab.ntt.co.jp> <13510.1550677844@sss.pgh.pa.us> <35b02675-83c2-a12b-961a-fec249b06f35@lab.ntt.co.jp> <20190222165932.GG28750@telsasoft.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: User-Agent: Mutt/1.5.23 (2014-03-12) List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Precedence: bulk On Sat, Feb 23, 2019 at 02:54:35AM +0900, Amit Langote wrote: > > On Fri, Feb 22, 2019 at 09:45:38PM +0900, Amit Langote wrote: > > > I have updated the inheritance expansion patch. > > > > > > Patch 0001 rewrites optimizer/utils/inherit.c, so that it allows > > > > Thanks for your continued work on this. > > > > I applied v23 patch and imported one of our customers' schema, and ran explain > > on a table with 210 partitions. With patch applied there are 10x fewer system > > calls, as intended. > > OK, great. I guess you were running SELECT? Just in case you missed, > the patch to improve UPDATE/DELETE scalability is no longer part of > this patch series. Yes, I understand the scope is reduced. Actually, when I tested last month, I don't think I realized that UPDATE/DELETE was included. Otherwise I would've also tested to see if it resolves the excessive RAM use with many partitions, with the explanation given that query is being replanned for every partition. I set target version to v12. https://commitfest.postgresql.org/22/1778/ Justin