Re: Avoiding roundoff error in pg_sleep()
От | Vladlen Popolitov |
---|---|
Тема | Re: Avoiding roundoff error in pg_sleep() |
Дата | |
Msg-id | cbeb760a947acc2deab9cda0ee3782ef@postgrespro.ru обсуждение исходный текст |
Ответ на | Re: Avoiding roundoff error in pg_sleep() ("David G. Johnston" <david.g.johnston@gmail.com>) |
Ответы |
Re: Avoiding roundoff error in pg_sleep()
Re: Avoiding roundoff error in pg_sleep() |
Список | pgsql-hackers |
Hi David, David G. Johnston писал(а) 2025-09-26 18:08: > On Friday, September 26, 2025, Vladlen Popolitov > <v.popolitov@postgrespro.ru> wrote: > >> It looks like sleep has the wrong place in a function. It should be >> an utility command, that does not start a transaction. > > Then write that command. We’re not going to change pg_sleep. > It’s works just as advertised. It _does_ not work as it advertised. Help page states: 1) "delay execution of the server process" 2) "pg_sleep makes the current session's process sleep" In reality it stops other backends too. > True, it probably should never be > used in production. yes, it should not be used, if you know, but even advanced users do not know the effect of this function. And it can be used by any user of the server. I just pointed attention, that this function could have bigger problem with high values of parameter, not only very small, if you consider problem with small value is really problem. -- Best regards, Vladlen Popolitov.
В списке pgsql-hackers по дате отправления: