Re: To what extent should tests rely on VACUUM ANALYZE? - Mailing list pgsql-hackers

From Tom Lane
Subject Re: To what extent should tests rely on VACUUM ANALYZE?
Date
Msg-id 3640269.1711647210@sss.pgh.pa.us
Whole thread Raw
In response to Re: To what extent should tests rely on VACUUM ANALYZE?  (Tomas Vondra <tomas.vondra@enterprisedb.com>)
Responses Re: To what extent should tests rely on VACUUM ANALYZE?
Re: To what extent should tests rely on VACUUM ANALYZE?
List pgsql-hackers
Tomas Vondra <tomas.vondra@enterprisedb.com> writes:
> Yeah. I think it's good to design the data/queries in such a way that
> the behavior does not flip due to minor noise like in this case.

+1

> But I'm a bit confused - how come the estimates do change at all? The
> analyze simply fetches 30k rows, and tenk only has 10k of them. So we
> should have *exact* numbers, and it should be exactly the same for all
> the analyze runs. So how come it changes like this?

It's plausible that the VACUUM ANALYZE done by test_setup fails
ConditionalLockBufferForCleanup() sometimes because of concurrent
activity like checkpointer writes.  I'm not quite sure how we
get from that to the observed symptom though.  Maybe the
VACUUM needs DISABLE_PAGE_SKIPPING?

            regards, tom lane



pgsql-hackers by date:

Previous
From: Jelte Fennema-Nio
Date:
Subject: Re: [EXTERNAL] Re: Add non-blocking version of PQcancel
Next
From: Tom Lane
Date:
Subject: Re: [EXTERNAL] Re: Add non-blocking version of PQcancel