Re: pgbench - doCustom cleanup

From: Fabien COELHO <coelho(at)cri(dot)ensmp(dot)fr>
To: Alvaro Herrera <alvherre(at)2ndquadrant(dot)com>
Cc: "Jamison, Kirk" <k(dot)jamison(at)jp(dot)fujitsu(dot)com>, PostgreSQL Developers <pgsql-hackers(at)lists(dot)postgresql(dot)org>
Subject: Re: pgbench - doCustom cleanup
Date: 2018-11-24 08:58:09
Message-ID: alpine.DEB.2.21.1811240904500.12627@lancre
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers


Hello Alvaro,

> I just pushed this. I hope not to have upset you too much with the
> subroutine thing.

Sorry for the feedback delay, my week was kind of overloaded…

Thanks for the push.

About the patch you committed, a post-commit review:

- the state and function renamings are indeed a good thing.

- I'm not fond of "now = func(..., now)", I'd have just passed a
reference.

- I'd put out the meta commands, but keep the SQL case and the state
assignment in the initial function, so that all state changes are in
one function… which was the initial aim of the submission.
Kind of a compromise:-)

See the attached followup patch which implements these suggestions. The
patch is quite small under "git diff -w", but larger because of the
reindentation as one "if" level is removed.

--
Fabien.

Attachment Content-Type Size
pgbench-state-change-followup-1.patch text/x-diff 11.2 KB

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Dean Rasheed 2018-11-24 09:02:42 Re: COPY FROM WHEN condition
Previous Message Amit Kapila 2018-11-24 07:49:36 Re: WIP: Avoid creation of the free space map for small tables