Hi, On Mon, Nov 9, 2026 at 3:13 PM surya poondla <[email protected]> wrote: > > I have a few comments: > 1. v3 now runs lazy_check_wraparound_failsafe() after the parallel index > pass only when the shared flag is set; > > matters in one corner case which is parallel workers use the GUC values > serialized when the parallel context was set up, while an autovacuum > leader can reload vacuum_failsafe_age while it waits for them. If > vacuum_failsafe_age is lowered at that point, only the leader's recheck > would notice it. I can share a reproducer if that's useful (doesn't happen in > normal scenarios)
Yeah, that's right. And that window, where users can lower the failsafe age to avoid wraparound, can be long in some cases. This can happen when the leader waits for the workers to finish index vacuuming (i.e. the leader gets small indexes compared to the workers). I don't think the fix is to keep an extra check in the leader. The issue is that we don't pass the failsafe age down to the workers like we do for the other cost delay params. Without it, the workers can't honor a changed failsafe age, and lowering it can be a valid way to avoid wraparound. So I think a better fix is to pass the failsafe age from the leader to the workers. That way both the leader and the workers check after each index. If the leader is waiting for the workers and the failsafe age changes, the workers will catch it, set the shmem flag, and the leader will report it. So we wouldn't need an extra check in the leader. > 2. The TAP test only counts the per-index lines. Could it also check for the > "bypassing nonessential maintenance" WARNING? Yeah, that would ensure the leader reported the detected failsafe. I will add it. > Apart from that, the patch behaved as expected in the other cases I tried: Thanks for verifying. -- Bharath Rupireddy Amazon Web Services: https://aws.amazon.com
