Re: pg_wal_lsn_diff

Поиск
Список
Период
Сортировка
От Tom Lane
Тема Re: pg_wal_lsn_diff
Дата
Msg-id 190699.1612630676@sss.pgh.pa.us
обсуждение исходный текст
Ответ на pg_wal_lsn_diff  (Tatsuo Ishii <ishii@sraoss.co.jp>)
Ответы Re: pg_wal_lsn_diff  (Tatsuo Ishii <ishii@sraoss.co.jp>)
Список pgsql-docs
Tatsuo Ishii <ishii@sraoss.co.jp> writes:
> According to the pg_wal_lsn_diff manual:
> pg_wal_lsn_diff ( lsn pg_lsn, lsn pg_lsn ) $B"*(B numeric

>     Calculates the difference in bytes between two write-ahead log
>     locations. This can be used with pg_stat_replication or some of
>     the functions shown in Table 9.87 to get the replication lag.

> It's not clear whether its return value is (first arg - second arg) or
> (second arg - first arg). The order matters because the return value
> could have a sign (it actually does first arg - second arg). Attached
> is a patch to fix the description.

+1 for fixing that.  Two notes though: first, your text doesn't agree
with the prototype ("ls1" should be "lsn1"), and second, I think it
would read better if you didn't split the phrase "difference in bytes".
That is,

-        Calculates the difference in bytes between two write-ahead log
+        Calculates the difference in bytes (lsn1 - lsn2) between two write-ahead log

Also maybe you should use the <parameter>lsn1</parameter> markup
in the text.

            regards, tom lane



В списке pgsql-docs по дате отправления:

Предыдущее
От: Tatsuo Ishii
Дата:
Сообщение: pg_wal_lsn_diff
Следующее
От: Tom Lane
Дата:
Сообщение: Re: The synopsis of "ALTER DEFAULT PRIVILEGES" statement is too difficult to understand