pg.ddx.io  pgsql-hackers@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Tomas Vondra <tomas.vondra@2ndquadrant.com>
To: pgsql-hackers@lists.postgresql.org
Subject: Re: Offline enabling/disabling of data checksums
Date: Thu, 27 Dec 2018 15:53:47 +0100
Message-ID: <bfa4e645-22ae-fe18-03d8-6a515c5116ae@2ndquadrant.com> (raw)
In-Reply-To: <CABUevEwbPVR_6Uv4D44fCd9tB_=aFxG4awUx+DJawD8_speuCA@mail.gmail.com>
References: <20181221201616.GD4974@nighthawk.caipicrew.dd-dns.de>
	<alpine.DEB.2.21.1812261900400.32444@lancre>
	<20181227011534.GD2106@paquier.xyz>
	<CABUevEwbPVR_6Uv4D44fCd9tB_=aFxG4awUx+DJawD8_speuCA@mail.gmail.com>



On 12/27/18 11:39 AM, Magnus Hagander wrote:
> 
> 
> On Thu, Dec 27, 2018 at 2:15 AM Michael Paquier <michael@paquier.xyz
> <mailto:michael@paquier.xyz>> wrote:
> 
>     On Wed, Dec 26, 2018 at 07:43:17PM +0100, Fabien COELHO wrote:
>     >> It adds an (now mandatory) --action parameter that takes either
>     verify,
>     >> enable or disable as argument.
>     >
>     > I'd rather have explicit switches for verify, enable & disable,
>     and verify
>     > would be the default if none is provided.
> 
>     Okay, noted for the separate switches.  But I don't agree with the
>     point of assuming that --verify should be enforced if no switches are
>     defined.  That feels like a trap for newcomers of this tool..
> 
> 
> Defaulting to the choice that makes no actual changes to the data surely
> is the safe choice,a nd not a trap :)
> 
> That said, this would probably be our first tool where you switch it
> between readonly and rewrite mode with just a switch, woudn't it? All
> other tools are either read-only or read/write at the *tool* level, not
> the switch level.
> 

Eh? Isn't pg_rewind "modify by default" with --dry-run switch to run in
a read-only mode. So I'm not sure what you mean by "tool level" here.

FWIW I'd prefer sticking to the same approach for this tool too, i.e.
have a "dry-run" switch that makes it read-only. IMHO that's pretty
common pattern.


regards

-- 
Tomas Vondra                  http://www.2ndQuadrant.com
PostgreSQL Development, 24x7 Support, Remote DBA, Training & Services




view thread (149+ messages)  latest in thread

Message-ID: <bfa4e645-22ae-fe18-03d8-6a515c5116ae@2ndquadrant.com>
Permalink:  ../bfa4e645-22ae-fe18-03d8-6a515c5116ae@2ndquadrant.com/
Also on:    postgresql.org/message-id/bfa4e645-22ae-fe18-03d8-6a515c5116ae@2ndquadrant.com

 · 

reply

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Reply to all the recipients using the --to and --cc options:
  reply via email

  To: pgsql-hackers@postgresql.org
  Cc: tomas.vondra@2ndquadrant.com, pgsql-hackers@lists.postgresql.org
  Subject: Re: Offline enabling/disabling of data checksums
  In-Reply-To: <bfa4e645-22ae-fe18-03d8-6a515c5116ae@2ndquadrant.com>

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox