Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtps (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1jnSzC-0004fI-7L for pgsql-hackers@arkaria.postgresql.org; Mon, 22 Jun 2020 20:24:10 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.92) (envelope-from ) id 1jnSzA-0002hC-VS for pgsql-hackers@arkaria.postgresql.org; Mon, 22 Jun 2020 20:24:08 +0000 Received: from magus.postgresql.org ([2a02:c0:301:0:ffff::29]) by malur.postgresql.org with esmtps (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1jnSzA-0002h4-Jc for pgsql-hackers@lists.postgresql.org; Mon, 22 Jun 2020 20:24:08 +0000 Received: from mail-pf1-x42b.google.com ([2607:f8b0:4864:20::42b]) by magus.postgresql.org with esmtps (TLS1.3:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.92) (envelope-from ) id 1jnSz6-0007xv-Ew for pgsql-hackers@postgresql.org; Mon, 22 Jun 2020 20:24:07 +0000 Received: by mail-pf1-x42b.google.com with SMTP id q17so1722652pfu.8 for ; Mon, 22 Jun 2020 13:24:04 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=j-davis-com.20150623.gappssmtp.com; s=20150623; h=message-id:subject:from:to:cc:date:in-reply-to:references :mime-version:content-transfer-encoding; bh=sCuIkMKwLsgtBz2hBUZIs7mYKE2un9IPxzJpuntojzc=; b=zNwGMRNXvaIa/bN/LMr+11wzSTD2x2R98UycwOiRW2yB4Wqfis93XvtXkrj7VgRyPP DN/rXNC7dj8aLUAsxeINvzCYRCeTQsjMFXyPVvWE8fWWFEuvUQQZIy5nGzdfSfl+tOwq 5A7w9XJ7BXrocVXhtOUiX3KudjEMtFHF/R3rDU6Mo5CZ3I6HraZDGQ5jPRQlXQz9kJPY GWJtlw+2tO9ORh+tLS/IMYeVhWqYyVD2fM0eAUQDVGxnDMfqAlmGFA2OrP7GKrKJllF0 6pZGnP6CS2mhpBiCSx4P/TeY/hz13aCVeFY0WbGIXnY/8L0KSqAZhFkvLhX5kohLn6b3 n0Gw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:message-id:subject:from:to:cc:date:in-reply-to :references:mime-version:content-transfer-encoding; bh=sCuIkMKwLsgtBz2hBUZIs7mYKE2un9IPxzJpuntojzc=; b=qyjKMt9H0uiUugj03RNBYHTfb0G44MicYbJjuPM+vHMnCphP6cq7yAQ5HrgCmS59/g Dkzbq+ei6quDrtjPfETuAryN1BgmLJnTdqkzduK4MvuC6NB460kjsGlRT2xVWz8AP39Q lshr7ijE4/f9Mq8/pdi0m+CFLQsHWNr6HEm9Owb1kGWu554LEFq3SozE2dp8QZ0iJ76p XDVwxfOsDGDqU7IQ865ty33Qs2HNDSPpwRlR4oTZk7HyaGAopme9SNVuaxXqYjp47zJJ +jdASxRBkWWomNJ/t1ZMqH89029VewR1OzrZmJ4qBjb7aLD9iKIEsA7gjaMv6rd4WNlz 1yIg== X-Gm-Message-State: AOAM533aTocr0p5UnhqzOr7yp1GGYO2uWm2rgdwpgZjVivkUIIb82s0Q 4GXIKftlnEkp0w92dlFSCl+UWw== X-Google-Smtp-Source: ABdhPJx2sgvenV6Fc7qGRsaiphL6FpHP8oSl5+jmVUm6hXSymMrz9dzuon5L/2Id5jQiOai+tgDq9w== X-Received: by 2002:a62:7610:: with SMTP id r16mr21648487pfc.70.1592857442295; Mon, 22 Jun 2020 13:24:02 -0700 (PDT) Received: from jdavis.lan (c-73-231-146-4.hsd1.ca.comcast.net. [73.231.146.4]) by smtp.gmail.com with ESMTPSA id s197sm14728711pfc.188.2020.06.22.13.24.00 (version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256); Mon, 22 Jun 2020 13:24:01 -0700 (PDT) Message-ID: <129c8f1739957589584d9525e1d8782eae3f412f.camel@j-davis.com> Subject: Re: Default setting for enable_hashagg_disk From: Jeff Davis To: Robert Haas Cc: Justin Pryzby , Melanie Plageman , Tomas Vondra , "pgsql-hackers@postgresql.org" Date: Mon, 22 Jun 2020 13:23:58 -0700 In-Reply-To: References: <9d9d1e1252a52ea1bad84ea40dbebfd54e672a0f.camel@j-davis.com> <20200407223900.GT2228@telsasoft.com> <20200409114855.h4hh7e2wt77p56sv@development> <6292f5a766198d5745eb8cc17ac736366056671d.camel@j-davis.com> <20200610021544.GA14879@telsasoft.com> <8bff2e4e8020c3caa16b61a46918d21b573eaf78.camel@j-davis.com> Content-Type: text/plain; charset="UTF-8" X-Mailer: Evolution 3.28.5-0ubuntu0.18.04.2 Mime-Version: 1.0 Content-Transfer-Encoding: 7bit List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Precedence: bulk On Mon, 2020-06-22 at 15:28 -0400, Robert Haas wrote: > The weirdness is the problem here, at least for me. Generally, I > don't > like GUCs of the form give_me_the_old_strange_behavior=true I agree with all of that in general. > I don't think it necessarily implies that either. I do however have > some concerns about people using the GUC as a crutch. Another way of looking at it is that the weird behavior is already there in v12, so there are already users relying on this weird behavior as a crutch for some other planner mistake. The question is whether we want to: (a) take the weird behavior away now as a consequence of implementing disk-based HashAgg; or (b) support the weird behavior forever; or (c) introduce a GUC now to help transition away from the weird behavior The danger with (c) is that it gives users more time to become more reliant on the weird behavior; and worse, a GUC could be seen as an endorsement of the weird behavior rather than a path to eliminating it. So we could intend to do (c) and end up with (b). We can mitigate this with documentation warnings, perhaps. > I am slightly > worried that this is going to have hard-to-fix problems and that > we'll > be stuck with the GUC for that reason. Without the GUC, it's basically a normal cost-based decision, with all of the good and bad that comes with that. > Now if that is the case, is > removing the GUC any better? Maybe not. These decisions are hard, and > I am not trying to pretend like I have all the answers. I agree that there is no easy answer. My philosophy here is: if a user does experience a plan regression due to my change, would it be reasonable to tell them that we don't have any escape hatch or transition period at all? That would be a tough sell for such a common plan type. Regards, Jeff Davis