pg.ddx.io  pgsql-committers@postgresql.org mailing list archive  
help / color / mirror / Atom feed
pgsql: Use access() to check file existence in GetNewRelFileNode()
4+ messages / 3 participants
[nested] [flat]

* pgsql: Use access() to check file existence in GetNewRelFileNode()
@ 2018-07-08 10:00 Michael Paquier <michael@paquier.xyz>
  2018-07-08 14:05 ` Re: pgsql: Use access() to check file existence in GetNewRelFileNode() Andrew Dunstan <andrew.dunstan@2ndquadrant.com>
  0 siblings, 1 reply; 4+ messages in thread

From: Michael Paquier @ 2018-07-08 10:00 UTC (permalink / raw)
  To: pgsql-committers@lists.postgresql.org

Use access() to check file existence in GetNewRelFileNode()

Previous code used BasicOpenFile() and close() just to check for a file
collision, while there is no need to hold open a file descriptor but
that's an overkill here.

Author: Paul Guo
Reviewed-by: Peter Eisentraut, Michael Paquier
Discussion: https://postgr.es/m/CABQrizcUtiHaquxK=d4etBX8GF9kbZB50Nt1gO9_aN-e9SptyQ@mail.gmail.com

Branch
------
master

Details
-------
https://git.postgresql.org/pg/commitdiff/677da8c15d19c11465d78f18bfd5ceb5d6fc3af1

Modified Files
--------------
src/backend/catalog/catalog.c | 15 ++++-----------
1 file changed, 4 insertions(+), 11 deletions(-)



^ permalink  raw  reply  [nested|flat] 4+ messages in thread

* Re: pgsql: Use access() to check file existence in GetNewRelFileNode()
  2018-07-08 10:00 pgsql: Use access() to check file existence in GetNewRelFileNode() Michael Paquier <michael@paquier.xyz>
@ 2018-07-08 14:05 ` Andrew Dunstan <andrew.dunstan@2ndquadrant.com>
  2018-07-08 17:27   ` Re: pgsql: Use access() to check file existence in GetNewRelFileNode() Andres Freund <andres@anarazel.de>
  0 siblings, 1 reply; 4+ messages in thread

From: Andrew Dunstan @ 2018-07-08 14:05 UTC (permalink / raw)
  To: Michael Paquier <michael@paquier.xyz>; pgsql-committers@lists.postgresql.org



On 07/08/2018 06:00 AM, Michael Paquier wrote:
> Reviewed-by: Peter Eisentraut, Michael Paquier
>

I think if you're the committer you're assumed to have reviewed the 
patch :-)

cheers

andrew

-- 
Andrew Dunstan                https://www.2ndQuadrant.com
PostgreSQL Development, 24x7 Support, Remote DBA, Training & Services





^ permalink  raw  reply  [nested|flat] 4+ messages in thread

* Re: pgsql: Use access() to check file existence in GetNewRelFileNode()
  2018-07-08 10:00 pgsql: Use access() to check file existence in GetNewRelFileNode() Michael Paquier <michael@paquier.xyz>
  2018-07-08 14:05 ` Re: pgsql: Use access() to check file existence in GetNewRelFileNode() Andrew Dunstan <andrew.dunstan@2ndquadrant.com>
@ 2018-07-08 17:27   ` Andres Freund <andres@anarazel.de>
  2018-07-09 01:36     ` Re: pgsql: Use access() to check file existence in GetNewRelFileNode() Michael Paquier <michael@paquier.xyz>
  0 siblings, 1 reply; 4+ messages in thread

From: Andres Freund @ 2018-07-08 17:27 UTC (permalink / raw)
  To: Andrew Dunstan <andrew.dunstan@2ndquadrant.com>; +Cc: Michael Paquier <michael@paquier.xyz>; pgsql-committers@lists.postgresql.org

Hi,

On 2018-07-08 10:05:53 -0400, Andrew Dunstan wrote:
> On 07/08/2018 06:00 AM, Michael Paquier wrote:
> > Reviewed-by: Peter Eisentraut, Michael Paquier
> > 
> 
> I think if you're the committer you're assumed to have reviewed the patch
> :-)

I personally think it makes sense to put oneself there. At least I order
the Reviewed-By etc lists roughly by the amount of work done. Sometimes
you come across a patch where others have done most of the review work,
so it's sensible to put yourself last. In other cases you might have
spent months of effort - so first.

Greetings,

Andres Freund




^ permalink  raw  reply  [nested|flat] 4+ messages in thread

* Re: pgsql: Use access() to check file existence in GetNewRelFileNode()
  2018-07-08 10:00 pgsql: Use access() to check file existence in GetNewRelFileNode() Michael Paquier <michael@paquier.xyz>
  2018-07-08 14:05 ` Re: pgsql: Use access() to check file existence in GetNewRelFileNode() Andrew Dunstan <andrew.dunstan@2ndquadrant.com>
  2018-07-08 17:27   ` Re: pgsql: Use access() to check file existence in GetNewRelFileNode() Andres Freund <andres@anarazel.de>
@ 2018-07-09 01:36     ` Michael Paquier <michael@paquier.xyz>
  0 siblings, 0 replies; 4+ messages in thread

From: Michael Paquier @ 2018-07-09 01:36 UTC (permalink / raw)
  To: Andres Freund <andres@anarazel.de>; +Cc: Andrew Dunstan <andrew.dunstan@2ndquadrant.com>; pgsql-committers@lists.postgresql.org

On Sun, Jul 08, 2018 at 10:27:33AM -0700, Andres Freund wrote:
> On 2018-07-08 10:05:53 -0400, Andrew Dunstan wrote:
>> I think if you're the committer you're assumed to have reviewed the patch
>> :-)
> 
> I personally think it makes sense to put oneself there. At least I order
> the Reviewed-By etc lists roughly by the amount of work done. Sometimes
> you come across a patch where others have done most of the review work,
> so it's sensible to put yourself last. In other cases you might have
> spent months of effort - so first.

Yeah, that's my line of thoughts as well.  So it is not strange to me
either to put oneself in any lists if adapted.
--
Michael

Attachments:

  signature.asc (application/pgp-signature, 832B) download

^ permalink  raw  reply  [nested|flat] 4+ messages in thread


end of thread, other threads:[~2018-07-09 01:36 UTC | newest]

Thread overview: 4+ messages (download: mbox mbox.gz follow: Atom feed)
-- links below jump to the message on this page --
2018-07-08 10:00 pgsql: Use access() to check file existence in GetNewRelFileNode() Michael Paquier <michael@paquier.xyz>
2018-07-08 14:05 ` Andrew Dunstan <andrew.dunstan@2ndquadrant.com>
2018-07-08 17:27   ` Andres Freund <andres@anarazel.de>
2018-07-09 01:36     ` Michael Paquier <michael@paquier.xyz>

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