Re: PGConnection.getNotifications(0) doesn't block

Поиск
Список
Период
Сортировка
От rob stone
Тема Re: PGConnection.getNotifications(0) doesn't block
Дата
Msg-id e37e010810077db4ef0c33e045c0657de85bda1d.camel@tpg.com.au
обсуждение исходный текст
Ответ на PGConnection.getNotifications(0) doesn't block  (Pawel Veselov <pawel.veselov@gmail.com>)
Ответы Re: PGConnection.getNotifications(0) doesn't block
Список pgsql-jdbc
Hello,

On Thu, 2023-08-03 at 16:04 +0200, Pawel Veselov wrote:
> Hello.
>
> I'm implementing a bit that is expected to wait for published channel
> notifications,
> and once there are any - process them.
>
> I'm using PGConnection.getNotifications(0), but that immediately
> returns an empty
> array, and doesn't block like JavaDoc says it should.
>
> I'm on 42.6.0.
>
> What am I missing?
>
> Thank you.
>
>

Have you read the JDBC docs
https://jdbc.postgresql.org/documentation/server-prepare
which has a section about Listen/Notify?

HTH





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

Предыдущее
От: Pawel Veselov
Дата:
Сообщение: Re: PGConnection.getNotifications(0) doesn't block
Следующее
От: Pawel Veselov
Дата:
Сообщение: Re: PGConnection.getNotifications(0) doesn't block