Re: Backpatch b61d161c14 (Introduce vacuum errcontext ...) - Mailing list pgsql-hackers

From Justin Pryzby
Subject Re: Backpatch b61d161c14 (Introduce vacuum errcontext ...)
Date
Msg-id 20200622204311.GF17995@telsasoft.com
Whole thread Raw
In response to Re: Backpatch b61d161c14  (Andres Freund <andres@anarazel.de>)
Responses Re: Backpatch b61d161c14 (Introduce vacuum errcontext ...)
List pgsql-hackers
On Mon, Jun 22, 2020 at 01:09:39PM -0700, Andres Freund wrote:
> On 2020-06-22 10:35:47 +0530, Amit Kapila wrote:
> > I propose to backpatch b61d161c14 [1] (Introduce vacuum errcontext to
> > display additional information.).
...
> I think having the additional information in the back branches would be
> good. But on the other hand I think this is a somewhat large change
> to backpatch, and it hasn't yet much real world exposure.

I see that's nontrivial to cherry-pick due to parallel vacuum changes, and due
to re-arranging calls to pgstat_progress.

Since the next minor releases are in August, and PG13 expected to be released
~October, we could defer backpatching until November (or later).

> I'm also uncomfortable with the approach of just copying all of
> LVRelStats in several places:
> 
> >  /*
> > @@ -1580,9 +1648,15 @@ lazy_vacuum_page(Relation onerel, BlockNumber blkno, Buffer buffer,
> >      int            uncnt = 0;
> >      TransactionId visibility_cutoff_xid;
> >      bool        all_frozen;
> > +    LVRelStats    olderrinfo;

I guess the alternative is to write like

LVRelStats    olderrinfo = {
    .phase = vacrelstats.phase,
    .blkno = vacrelstats.blkno,
    .indname = vacrelstats.indname,
};

-- 
Justin



pgsql-hackers by date:

Previous
From: Ranier Vilela
Date:
Subject: Re: Parallel Seq Scan vs kernel read ahead
Next
From: Andres Freund
Date:
Subject: Re: [HACKERS] Custom compression methods