Re: Small refactoring around vacuum_open_relation - Mailing list pgsql-hackers

From Ashutosh Bapat
Subject Re: Small refactoring around vacuum_open_relation
Date
Msg-id CAExHW5uJtbgKdn1nRQ3GP+uei-4ETLtcZpPRP9e8VAZh3v1UHg@mail.gmail.com
Whole thread Raw
In response to Re: Small refactoring around vacuum_open_relation  (Alvaro Herrera <alvherre@alvh.no-ip.org>)
List pgsql-hackers
> On Thu, Jan 9, 2025 at 5:30 PM Daniel Gustafsson <daniel@yesql.se> wrote:
>
> > On 9 Jan 2025, at 11:45, Alvaro Herrera <alvherre@alvh.no-ip.org> wrote:
>
> > Dunno what others think, this seems useless churn to me.
>
> I agree, I don't see this providing enough value to warrant the changes.
>

I agree about most of the changes however

>
> > I found some more
> > static const struct
> > {
> > LOCKMODE hwlock;
> > int lockstatus;
> > int updstatus;
> > }
> >
> > tupleLockExtraInfo[MaxLockTupleMode + 1] =
> >
> > hwlock should be hwlockmode?

this one looks useful. Variable name hwlock indicates some kind of
lock (object) not a mode in which it should be locked. This is
especially so when the next variable is named lockstatus indicating
status of the lock.

--
Best Wishes,
Ashutosh Bapat



pgsql-hackers by date:

Previous
From: Peter Smith
Date:
Subject: Re: Question about behavior of deletes with REPLICA IDENTITY NOTHING
Next
From: Nazir Bilal Yavuz
Date:
Subject: Re: Make pg_stat_io view count IOs as bytes instead of blocks