Re: Allow default \watch interval in psql to be configured

Поиск
Список
Период
Сортировка
От Pavel Stehule
Тема Re: Allow default \watch interval in psql to be configured
Дата
Msg-id CAFj8pRB53mJGEiiik_7dNxVVejYXTO6iScES-en6G5UnGoC5fA@mail.gmail.com
обсуждение исходный текст
Ответ на Re: Allow default \watch interval in psql to be configured  (Heikki Linnakangas <hlinnaka@iki.fi>)
Список pgsql-hackers


čt 10. 10. 2024 v 2:02 odesílatel Michael Paquier <michael@paquier.xyz> napsal:
On Wed, Oct 09, 2024 at 04:24:27PM +0200, Daniel Gustafsson wrote:
> Fixed.

-        double        sleep = 2;
+        double        sleep = pset.watch_interval;

This forces the use of seconds as unit.  The interval values I have
been using a lot myself are between 0.2s and 0.5s because I usually
want a lot more granularity in my lookups than the 1s interval.  Could
it be better to allow values lower than 1s or let this value be a
string with optional "s" or "ms" units?

Linux "watch" uses just seconds. If I remember correctly the psql doesn't use units in settings, so I prefer just the value from interval 0.1 .. 3600 * n

and the number can be rounded to 0.1

Regards

Pavel

 
--
Michael

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