Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.94.2) (envelope-from ) id 1v7J2W-000bCz-9o for pgsql-hackers@arkaria.postgresql.org; Fri, 10 Oct 2025 19:44:32 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.94.2) (envelope-from ) id 1v7J2S-00E441-SB for pgsql-hackers@arkaria.postgresql.org; Fri, 10 Oct 2025 19:44:29 +0000 Received: from magus.postgresql.org ([2a02:c0:301:0:ffff::29]) by malur.postgresql.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.94.2) (envelope-from ) id 1v7J2S-00E43s-GZ for pgsql-hackers@lists.postgresql.org; Fri, 10 Oct 2025 19:44:29 +0000 Received: from mail-io1-xd35.google.com ([2607:f8b0:4864:20::d35]) by magus.postgresql.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256 (Exim 4.96) (envelope-from ) id 1v7J2R-001TDx-0B for pgsql-hackers@postgresql.org; Fri, 10 Oct 2025 19:44:29 +0000 Received: by mail-io1-xd35.google.com with SMTP id ca18e2360f4ac-938bf212b72so90403739f.1 for ; Fri, 10 Oct 2025 12:44:26 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1760125465; x=1760730265; darn=postgresql.org; h=in-reply-to:content-disposition:mime-version:references:message-id :subject:cc:to:from:date:from:to:cc:subject:date:message-id:reply-to; bh=qXR+wi8IYFuOpfjaK8IZdl2gt7ff2xh84xe4JD3IDN8=; b=V3jRdvB97wkIBpXq5riKrHCdXejTT4+beu1xPsw0Z7bJsDlBi7FuuhqdJKuuP7SISK dhN9zcknrzQihkTmB+4BuCiEpcHkd0g/N/zHqqnCbLgVQQgv6jCkPegllmU2s9UCROu9 HWIVAhrJ7sTSpEZuxI31tRcr/FcO0WXOl9HuMPG6epxp5o6fzbnDYgrq/u9hNwYeDxgf lL0Llw306mqgbGD9kOsKoUa/T0LdwnjG7gSxsDfqM5E5GzOxWia/TAXmzarcxZ8xHybA IYEuH2xMsjLGn/245eDR/SWo9TZYL0vskeoE9xHdk3LTWlr2CswLMnac0+DgbOisdwWG zdnQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1760125465; x=1760730265; h=in-reply-to:content-disposition:mime-version:references:message-id :subject:cc:to:from:date:x-gm-message-state:from:to:cc:subject:date :message-id:reply-to; bh=qXR+wi8IYFuOpfjaK8IZdl2gt7ff2xh84xe4JD3IDN8=; b=n+nvxoPWqQYfnslhcxBIgeKLnBKlXS1JatY5wSGTysjYiXNImn0bYGHvIatag+UQZG eWjMLWIlec+RqhKNZ9piUa4RcyEJre512gqUKR9CdqH8yC9AFwCUBeKv+4eT0tsQ40iU jv4K7seUWD6OUk6e4GW5uBgdMr1lnwEyvXD0ZYCH0am+EkpmHFSS7jiNE0rYkE6+GOuk KhBvofr5vuC6E4nUphG48Fgj8nlbUamTyxLJXZcQboxrnGn/lidJxf4HwLPC3Q+Kr1xH 8hQlRHwnvs7R1JjkFSMbkChM0cTcAdT0swWbJah/r6VZbjwj4dvxJ2VCxGc1Q3BjZatv DsjQ== X-Forwarded-Encrypted: i=1; AJvYcCXwuYeaeaV7ErCzgUjYIyZ8XclHwQDYkFlgtwo4oU5+EYwBsPA/AdYcSXicoPvYvjYwRv3lsiPioO6o2OSL@postgresql.org X-Gm-Message-State: AOJu0YxPpGs5/FZDAex3LULzFCPi6dk+ZPbgPnyUSiaDJx49ytUeN0jS mECyAtVllFVSxcqUZ19XFWUDc5dpc+qDI+pWpuOEwbRhRF9cAei92d96 X-Gm-Gg: ASbGncurRYuz3moJ8wrk8Xzb6ZfufuYPd70xV2zPBLzKJ72Y20i92W+G4+i9LK5NH7z DsCCgMjegl5CJRExgshnVrLgnGNQQg2KggILfydVEBNltiIXcgO8MVI896FvtqyZjPdP4ZpEmc2 1JJp8992vumqUV9fsCEyXf0+6sA01oXq4j9974F8JiXFTviz5qNuHuGRFRoEekHWCmNPSnXvBI9 e7cKwsgRIM7xNmIp+L4yxIDJMqcQ0V8E5q7TF6NWcW2p6Bhx7RqMQuxc1kf/pqQw5TQBig3pT0U phz1SpqLJK9kq3khHAKN9FJ8ZRpghM15v5h2r5GoFDWEd9akjHRCCpT9KzzT4NzgWss8DIBfROO 7QvSG5y98oum5vK9nrdkl1eCMSkeKkuTZq2cMinkvy/1KcLTbQVo9AZTB+5duAgWu29JBtd7HxN APyY+G363OnvROvBxIlnQ4YitPAbu/wcQ= X-Google-Smtp-Source: AGHT+IGNaC70p2PFH5reFiH8IK2C6W6uS4rGnId1DHuxvb9fnUbXOCmq2J+AznejFn4i3d4VsBrFWQ== X-Received: by 2002:a05:6e02:1fed:b0:42d:876e:61bd with SMTP id e9e14a558f8ab-42f87418fa6mr124633765ab.28.1760125464567; Fri, 10 Oct 2025 12:44:24 -0700 (PDT) Received: from nathan (162-195-168-172.lightspeed.stlsmo.sbcglobal.net. [162.195.168.172]) by smtp.gmail.com with ESMTPSA id e9e14a558f8ab-42f90343080sm23762425ab.22.2025.10.10.12.44.23 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 10 Oct 2025 12:44:23 -0700 (PDT) Date: Fri, 10 Oct 2025 14:44:22 -0500 From: Nathan Bossart To: Robert Haas Cc: David Rowley , Jeremy Schneider , Sami Imseih , pgsql-hackers@postgresql.org Subject: Re: another autovacuum scheduling thread Message-ID: References: <20251008164057.6bceb9ed@ardentperf.com> <20251008172727.3befd129@ardentperf.com> <20251008182520.6e05a8b8@ardentperf.com> <20251008184740.328d45de@ardentperf.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Archived-At: Precedence: bulk Thanks for taking a look. On Fri, Oct 10, 2025 at 02:42:57PM -0400, Robert Haas wrote: > I think this is a reasonable starting point, although I'm surprised > that you chose to combine the sub-scores using + rather than Max. My thinking was that we should consider as many factors as we can in the score, not just the worst one. If a table has medium bloat and medium wraparound risk, should it always be lower in priority to something with large bloat and small wraparound risk? It seems worth exploring. I am curious why you first thought of Max. > When I've thought about this problem -- and I can't claim to have > thought about it very hard -- it's seemed to me that we need to (1) > somehow normalize everything to somewhat similar units and (2) make > sure that severe wraparound danger always wins over every other > consideration, but mild wraparound danger can lose to severe bloat. Agreed. I need to think about this some more. While I'm optimistic that we could come up with some sort of normalization framework, I deperately want to avoid super complicated formulas and GUCs, as those seem like sure-fire ways of ensuring nothing ever gets committed. -- nathan