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 1w99c6-001DzB-0s for pgsql-hackers@arkaria.postgresql.org; Sat, 04 Apr 2026 22:37:10 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.96) (envelope-from ) id 1w99b5-000dTi-2W for pgsql-hackers@arkaria.postgresql.org; Sat, 04 Apr 2026 22:36:08 +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 1w99b5-000dTY-1O for pgsql-hackers@lists.postgresql.org; Sat, 04 Apr 2026 22:36:07 +0000 Received: from mail-ed1-x530.google.com ([2a00:1450:4864:20::530]) by magus.postgresql.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256 (Exim 4.98.2) (envelope-from ) id 1w99b3-00000000dKI-0dgg for pgsql-hackers@postgresql.org; Sat, 04 Apr 2026 22:36:07 +0000 Received: by mail-ed1-x530.google.com with SMTP id 4fb4d7f45d1cf-66c304dbfd2so1709887a12.0 for ; Sat, 04 Apr 2026 15:36:04 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1775342162; cv=none; d=google.com; s=arc-20240605; b=blXLTpEmooEWNqobxJDa2zoq4CauEgSUO0ysrjnntCN4aA0DRqUwjWBPLOJu1yhqj/ W5yYKIM0H0FY5bTL2e2PR5H+W8Mm+6EX5P+A/CpFV6QmT1hbmyAi7m9ikwcPYbCoBDtD x3XS7ISfiFStkuf87/lq0g7e24oP4hn77WKUAaKbdZdDtvKxvBtsNL5OZ3fiC2uzqUPf 5XX4dEqHsaN/pXZa32XtEiYSz10MxUvq/+t6FhTXkqHRQT92Po6XePESx1diUQ1USd/s J3eK6Zim5Rp688xRbrNOZymG6yMvQYb+eNdKGcSId3vZcI8L6rrhinh8muopl+D5COpZ lgog== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20240605; h=content-transfer-encoding:cc:to:subject:message-id:date:from :in-reply-to:references:mime-version:dkim-signature; bh=Ix8OzPNU07/KC8PdiauDRNmn5yIk4qpVD+/r82kLJ5U=; fh=JK+Vc3W+BPfYmVHJV+nvf+6xkUAIKBhLQ5pA9T/og2g=; b=dbQptAhkwNUBR8DWq7VsPoUMY+gWe+LYuUZbYAerI2gP32a7dQSDrhf024Oh/vtqWQ a4ODnBHw4FtYpyduS1ScoSxuc7eKROyg2mz1acV7gtsTt80HofagUpxeF8Q/Oa0IfxYv 1aEeEWpaz6VqGG+hK76Z95hnMOI4UzHDD+VQ0CHqBFqFQOD8rQE5HxX21kLjIJDP3xKG 2ftPzlgyD6/lg3F0z1nlE8pGj1QXR/xehP8LQhd0aD/oQyHYM75jwMZ74aRVaH+fQsai LKgfcP+NMO/9yIFORS/rIqkoNACua1WZvpeKj5mFnY9hzFPoaLTYF7riIwNO1LpPMzN8 BVeg==; darn=postgresql.org ARC-Authentication-Results: i=1; mx.google.com; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20251104; t=1775342162; x=1775946962; darn=postgresql.org; h=content-transfer-encoding:cc:to:subject:message-id:date:from :in-reply-to:references:mime-version:from:to:cc:subject:date :message-id:reply-to; bh=Ix8OzPNU07/KC8PdiauDRNmn5yIk4qpVD+/r82kLJ5U=; b=KhEuG5ULGemvIec7zuSgHrLFLRrgqv23xpNZcc1PzrnRo1lI4siLPSijePHoInY/PY FbYmtLplTlJW6yTmuWcaE/m7AglLlX7I9QglfwajV7WwQ1VHUN2y/mBiU+iX41xp5XPi 10lQuvnlYCA1mVIfmd7X4meLV9ft2X2nRtO0qytNvxsC31FL5KDRLgTTLBztsr5dW+bS pM9n0c/WQjJihpg72N4zSdka8tJRjzm9DCNwKOmebhRta6eMTbu6TRuzGuixJpx9Qxlr T/GTPqw5ZV43ejED1BLWsVJ2ZvBdhBJR19hMPdyghgGDjMAT7EL2Xv69UXYDgpEYgLZW GF6w== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20251104; t=1775342162; x=1775946962; h=content-transfer-encoding:cc:to:subject:message-id:date:from :in-reply-to:references:mime-version:x-gm-gg:x-gm-message-state:from :to:cc:subject:date:message-id:reply-to; bh=Ix8OzPNU07/KC8PdiauDRNmn5yIk4qpVD+/r82kLJ5U=; b=G8SJ/53tz/FVrQrFUlZdauDyGty0sWDXbz6QdkVFZ5KR9OS+39Yr6dvEEBcPM3JbxH JLsy/ANrQKlo21ywSsSUu09vyojnBeID54zwqrjgGtWAJM0jZRumU2+h709TyRxEaghT N71faJfPMJ40J9VAVXZe5OnraKBvqHNI6ZbIWe2rKbkkFgRHAAH99bJE5Z8VhdoX4dEh 7Zrz+kLoJcx0aaj2ouWYBt4BEUIihq04VEQNVcurTnhrPz2r1Y4YNGosiP+1oskmsM3A CG8Q9eP5tiZVb6iTzrxFh0uQNEDA+Waof3PnOid76P2vAGQkOLzOLuAEy2uMLHIy7Ufq 5Yvg== X-Forwarded-Encrypted: i=1; AJvYcCURnV835jfJhuK5lZolYnQ1A+MT0cl65XPHUVmZYlRK6bFY2PXnnNpRtDmRfDOfSMM17Eo9vCu73eSmad8W@postgresql.org X-Gm-Message-State: AOJu0YzwHte6rE8v21/a705bc7NLPxkT5vFkoQzmJnwFnPwfF6YngdK6 KPuk6yAioXs+xgNWK9mwYktk9vXxZRSqMfYNjNPmu8EYRq3r5sE+MEwMQPkxcJu5b5ZKD93dATV 9cCCcxyJ96n+aMwzeKqqEHx+KM8BBvek= X-Gm-Gg: AeBDieuRZnNkq+GqLrA9IcIlcZv5jHtn5mw7vKMT/Lzrkm8++lKXXkBBWqHKMIbvjwN UxmvTmXYGpJ2bX3LsdMf8XiKwZcudQgfpLHdV1SKq75ZSgql2vQmfWckm+QqhfUY5WU9N+q0H4p rqZQgLW6pvD12uHIznwjmaLo6XHPpaSafdl/MgA9XoOz3k+f+IxXxGuVs2o+UTnUOLPv2Jm9G/B GRyj8HaGhJNgrbAprvW2Y85e75xUz84srzldcccWtNwtKbBsxwW/8bY7qDoaciV//pTaNx4HhuB ZblBDg== X-Received: by 2002:a05:6402:3787:b0:66e:8ae9:7529 with SMTP id 4fb4d7f45d1cf-66e8ae9759emr1184680a12.0.1775342162214; Sat, 04 Apr 2026 15:36:02 -0700 (PDT) MIME-Version: 1.0 References: In-Reply-To: From: Sami Imseih Date: Sat, 4 Apr 2026 17:35:50 -0500 X-Gm-Features: AQROBzCez9u1_zh-lhW2LUW3j6PD1nBLf7KE9QAMV7uqCJg8CVmhWZZcGzXIC9I Message-ID: Subject: Re: Add pg_stat_autovacuum_priority To: Nathan Bossart Cc: Bharath Rupireddy , Robert Treat , satyanarlapuram@gmail.com, pgsql-hackers Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Archived-At: Precedence: bulk > >> If we did report booleans, I would probably argue for just reporting > >> dovacuum and doanalyze and calling out the criteria for why they may b= e > >> false even when it looks like the table needs processing. > > > > Yes, we only require a needs_analyze and needs_vacuum. The latter > > can be set to true due to thresholds or wraparound. But, I don't think = we > > should rely on the dovacuum or doanalyze, instead we can just have a fl= ag > > in AutoVacuumScores->needs and track what is needed. This will separate > > the autovacuum processing from the reporting. > > Sorry for going in circles about this, but I'm not seeing why we wouldn't > just return the booleans that relation_needs_vacanalyze() already returns= . > I think the question people will have is "what will autovacuum process an= d > in what order?", and if we aren't giving them the exact same information > that autovacuum is using to make its decisions, then I'm not sure what is > the point. It's true that someone might disable autovacuum for a table a= nd > that it would otherwise be processed, but so be it. Maybe there=E2=80=99s no need to worry too much about the autovacuum disabl= ed case or track_counts being disabled when querying the view. Both are edge cases, and it seemed fairly trivial to compensate for this with what I had attached earlier. Anyhow, I will not push this point further. I am ok with proceeding with what you have in v12. The patches overall LGTM. Thanks! -- Sami