Re: Progress reporting for pg_verify_checksums

Michael Banck <michael.banck@credativ.de>

From: Michael Banck <michael.banck@credativ.de>
To: Michael Paquier <michael@paquier.xyz>
Cc: Kyotaro HORIGUCHI <horiguchi.kyotaro@lab.ntt.co.jp>, coelho@cri.ensmp.fr, alvherre@2ndquadrant.com, mailings@oopsware.de, thomas.munro@enterprisedb.com, pgsql-hackers@postgresql.org
Date: 2019-03-27T13:56:24Z
Lists: pgsql-hackers

Attachments

Hi,

Am Samstag, den 23.03.2019, 10:49 +0900 schrieb Michael Paquier:
> On Fri, Mar 22, 2019 at 02:23:17PM +0100, Michael Banck wrote:
> > The current version prints a newline when it progress reporting is
> > toggled off. Do you mean there is a hazard that this happens right when
> > we are printing the progress, so end up with a partly garbage line? I
> > don't think that'd be so bad to warrant further code complexitiy, after
> > all, the user explicitly wanted the progress to stop.
> > 
> > But maybe I am misunderstanding?
> 
> The latest patch does not apply because of mainly ed308d7.  Could you
> send a rebase?

I've rebased it now, see attached.

> FWIW, I would remove the signal toggling stuff from the patch and keep
> the logic simple at this stage.  Not having a solution which works on
> Windows is perhaps not a strong reason to not include it, but it's a
> sign that we could perhaps design something better, and that's
> annoying.  Personally I think that I would just use --progress all the
> time and not use the signaling part at all, my 2c.

We had this discussion already, and back then I was against dropping it
as well.

Do you see --progress being the default? I don't think this is in-line
with other project binaries, so I guess not?

If not, I guess your main point is that we might come up with a better
implementation/UI further down the road.  Which is fair enough, but I
don't think this is such an in-your-face feature that changing the way
it works in future releases would be a terrible breakage of backwards
compatibility. Even more so as it is solely an interactive feature and
cannot be used in scripts etc.


Michael

-- 
Michael Banck
Projektleiter / Senior Berater
Tel.: +49 2166 9901-171
Fax:  +49 2166 9901-100
Email: michael.banck@credativ.de

credativ GmbH, HRB Mönchengladbach 12080
USt-ID-Nummer: DE204566209
Trompeterallee 108, 41189 Mönchengladbach
Geschäftsführung: Dr. Michael Meskes, Jörg Folz, Sascha Heuer

Unser Umgang mit personenbezogenen Daten unterliegt
folgenden Bestimmungen: https://www.credativ.de/datenschutz

Commits

  1. Add progress reporting to pg_checksums

  2. Fix thinko when bumping on temporary directories in pg_verify_checksums

  3. Fix thinko when bumping on temporary directories in pg_checksums