Re: Function for listing archive_status directory - Mailing list pgsql-hackers

From 'Christoph Moench-Tegeder'
Subject Re: Function for listing archive_status directory
Date
Msg-id 20181005110641.GA48848@elch.exwg.net
Whole thread Raw
In response to RE: Function for listing archive_status directory  ("Iwata, Aya" <iwata.aya@jp.fujitsu.com>)
Responses RE: Function for listing archive_status directory  ("Iwata, Aya" <iwata.aya@jp.fujitsu.com>)
RE: Function for listing archive_status directory  ("Iwata, Aya" <iwata.aya@jp.fujitsu.com>)
List pgsql-hackers
Hi,

## Iwata, Aya (iwata.aya@jp.fujitsu.com):

> I think it is convenient to be able to check the archive_status
> directory contents information.
> 
> I reviewed patch. It applies and passes regression test.

Great, thanks!

> All similar function are named pg_ls_***dir. It is clear these functions
> return directory contents information.
> If the new function intends to display the contents of the directory,
> pg_ls_***dir style might be better (e.g. pg_ls_archive_statusdir).
> But everyone know archive_status is a directory...
> If you want to follow the standard naming, then you may add the dir.

I conciously omitted the "_dir" suffix - I'm not a great fan of long
function names, and we want to inspect the contents of archive_status
to find out about the status of the archiving process. But then, my
main concern is the functionality, not the name, we can easily change
the name. Is there any other opinion pro/contra the name?

> Do you watch this thread?
> https://www.postgresql.org/message-id/flat/92F458A2-6459-44B8-A7F2-2ADD3225046A@amazon.com
> They are also discussing about generic pg_ls function.

I'm aware of that threat, and that Michael just commited "pg_ls_tmpdir()".
I'm not that sure about Laurenz' idea regarding monitoring all the
database directories (but it doesn't hurt anybody...). Anyway, the
archive_status directory is not coupled to any specific database or
tablespace, so there's not too much overlap.

Regards,
Christoph

-- 
Spare Space


pgsql-hackers by date:

Previous
From: Etsuro Fujita
Date:
Subject: Re: Problems with plan estimates in postgres_fdw
Next
From: Peter Eisentraut
Date:
Subject: Re: transction_timestamp() inside of procedures