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.96) (envelope-from ) id 1w55Le-002sYx-2v for pgsql-hackers@arkaria.postgresql.org; Tue, 24 Mar 2026 17:15:23 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.96) (envelope-from ) id 1w55Ld-008729-0l for pgsql-hackers@arkaria.postgresql.org; Tue, 24 Mar 2026 17:15:21 +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.96) (envelope-from ) id 1w55Lc-008721-2p for pgsql-hackers@lists.postgresql.org; Tue, 24 Mar 2026 17:15:21 +0000 Received: from mail-oi1-x233.google.com ([2607:f8b0:4864:20::233]) by magus.postgresql.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256 (Exim 4.98.2) (envelope-from ) id 1w55La-00000000udO-2HG9 for pgsql-hackers@postgresql.org; Tue, 24 Mar 2026 17:15:21 +0000 Received: by mail-oi1-x233.google.com with SMTP id 5614622812f47-467fd082ffeso2361655b6e.1 for ; Tue, 24 Mar 2026 10:15:18 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20251104; t=1774372517; x=1774977317; 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=g3VlecfMTNHV4DjtAsug9WYs7CHgvyWaJS+EMUMJTUs=; b=ks6A7cXigdS/QbBoChaFxNuyRHK+1Rfb+D5/1O0VaberpkVze/k5qnXOQtlqV973th xHV9WcP4DC39QTznnSOb+1SGH5buxx2NwePwNqIi4wNnB+de6ErtQwPAz5tKhDhkEBig AoiXrGjNcA+VqsTf9CiGWVbmCqg3Ljr9+zxJq3uUipDr4NitkPZKjohgvB6WP3WFG/Fu w9RmwwUTCnmtp1l9vAhL2eMopXPZfUM2NpsB1gcNSABMVocnsofsY2zkqnCTbKV4M5BR A1Wj6r7G5H8I9nvTfFj45mxrH/ocVy+UfpiFiynRAuyd9WNMuPGL0DEvQFEFBfJ6Qlw7 wZTg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20251104; t=1774372517; x=1774977317; h=in-reply-to:content-disposition:mime-version:references:message-id :subject:cc:to:from:date:x-gm-gg:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=g3VlecfMTNHV4DjtAsug9WYs7CHgvyWaJS+EMUMJTUs=; b=BeZlpubhDCypsAvjmsuoLXBpQc5eJjwiFJyF6LZNQ/t1dx0iDXvvpSlB0C+In7kxjo 9FlTTG21mTNMY+njL9NRAZd24l9YRGR3ju7kLK6JOW0vA2QEZ8dnEzTbJ+vO6IQbATDL dlky2jPSCGc8FhIoCqYd583A8uVhVnKSF8PERrypmo5Km0LCf08yBOaAdor3a7zupXN0 8RggNJvJsovFy9DfewXyCcPP+xomdRjb/PnjQpTw8o/4sRhrcVFg/7mTN7+3KkyZshwq tk/hFhH6GMI8pIJQvUbR9IhDMeBRDvqQyC1IVSDXGx7tCMT1+lw9kD1RU6spA7s/mYKa ZaQA== X-Forwarded-Encrypted: i=1; AJvYcCUT6bTLMnhgiq9aqvE1kaxThZDpUCUB1mvDPumIXEnBnnANFCUaB7g71NskYibpAldbVRHu6lfu25MCShX2@postgresql.org X-Gm-Message-State: AOJu0YxhdDfqAw30asak9BmBfOUAfxz+hMJ/p2OaBxJeQgGfQcJZetFh idTvx70MFYgCdET3Oi9SR0n9DSCb4oDsUOJY26mgacgeilB5Ap50xa5d X-Gm-Gg: ATEYQzzOxTs2Ccju4bW5J4tpT8oKOGQydLG1PcWDYvTPJXAWVrP/Sa3AA14qYTdi+f7 WWxZR/wnBMMN1J2V3QDR4T5iTykUo9Ia5KxBEFWNF0AmOEFpRU181OkXYbXfcYjRDX9EaU50xpS Xf9EWgZJFha3IHrkvB1YXcolQt0AGN6C/yNBvM0/xyzwtg+VpqK8E9AcbNIJ+x0ItX9ewb5Z3vz fbu1m7yTauRdittgoI7Fa0cjGXcWO4otFrOIRudvFp/r7te1rg/3i3FikDsb1lJdg9fIIEyHqoq 6bs4U548UebmLvTd/JIahYam2LasCP3d97lhBkNfkQrQ30SfgcEHvrfYGwud3jddjX+EALK3uAr YWN4n3WxdFSVafIBQ7I5DEDea04+WlAKCe1zbC5jeQT5GIzJeXQ770ltQ3eZ8jFc8MN2TYkG6BZ om0tGmC2YIwuEs+QJLT7h7DSfiXJNgj+7fZq+aCBb9GYIBeR7NFnaTe3+NbT3WsIU5gpVcFMko0 QhSJ+pa0SrA9XMAz/Dsig== X-Received: by 2002:a05:6808:5187:b0:466:f3a2:dc34 with SMTP id 5614622812f47-46a5c79da6amr142273b6e.36.1774372517303; Tue, 24 Mar 2026 10:15:17 -0700 (PDT) Received: from nathan (162-195-168-172.lightspeed.stlsmo.sbcglobal.net. [162.195.168.172]) by smtp.gmail.com with ESMTPSA id 5614622812f47-467e7f45ce7sm9214231b6e.17.2026.03.24.10.15.15 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 24 Mar 2026 10:15:16 -0700 (PDT) Date: Tue, 24 Mar 2026 12:15:14 -0500 From: Nathan Bossart To: David Rowley Cc: Jim Nasby , Sami Imseih , Bharath Rupireddy , Greg Burd , Robert Haas , Robert Treat , Jeremy Schneider , pgsql-hackers Subject: Re: another autovacuum scheduling thread Message-ID: References: MIME-Version: 1.0 Content-Type: multipart/mixed; boundary="ulbzwYZq1NoRfQi9" Content-Disposition: inline In-Reply-To: List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Archived-At: Precedence: bulk --ulbzwYZq1NoRfQi9 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline On Tue, Mar 24, 2026 at 01:32:40PM +1300, David Rowley wrote: > +1 for main patch first. I do think a view would be useful as a > follow-up. However, which columns we put in that view might have some > influence on how the current patch should look. I think the view > should show the individual scores and the total score as the Max() of > the individual scores. If we didn't do that, it might be confusing to > the user which aspect of the score the final score is derived from. > That might mean that it'd be better to have > relation_needs_vacanalyze() output the scores individually, or perhaps > populate a struct that we pass in that gets allocated on the stack > during do_autovacuum(). That'd mean a bit less churn if we go with the > view containing individual scores. Agreed. Here's a first try at that. I also updated the DEBUG3 at the end of relation_needs_vacanalyze() to show the individual scores. The comment above that function might need some work, and we might need a bit of additional commentary elsewhere. -- nathan --ulbzwYZq1NoRfQi9 Content-Type: text/plain; charset=us-ascii Content-Disposition: attachment; filename=v15-0001-autovacuum-scheduling-improvements.patch