Re: Is it possible to get the Payload from a NOTIFY via the JDBC Driver?

Поиск
Список
Период
Сортировка
От Edvin Syse
Тема Re: Is it possible to get the Payload from a NOTIFY via the JDBC Driver?
Дата
Msg-id 6C37221E818AD94EB8593F2D10B7D62611A9B9@EX-2010-01.ad.sdhosting.no
обсуждение исходный текст
Ответ на Re: Is it possible to get the Payload from a NOTIFY via the JDBC Driver?  (Kris Jurka <books@ejurka.com>)
Список pgsql-jdbc
> This works with 9.0 and newer server versions.  The JDBC driver didn't
> need any changes to make that happen, so the comment never got
> updated.

Sweet, thanks :)

> > I'm also curious to know if there are any plans to implement async
> > support for notifications.
> >
> 
> Meaning a callback mechanism or just not needing to issue queries to the
> server?  Currently the JDBC driver supports an intermediate method
> depending on your connection type.  You only need to poll
> PGConnection.getNotifications, not issue server queries as long as you
> aren't connected via SSL.  The driver uses InputStream.available to
> determine when a notification is pending which isn't supported on all
> InputStreams.

It would be nice to be able to attach a listener that gets notifications in realtime as they come over the wire, but if
Iunderstand you correctly, I can atleast let a thread poll regularily, and it will not create any network traffic,
right?Is there a way to attach a listener with today's architecture?
 

-- Edvin

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

Предыдущее
От: Ian Pilcher
Дата:
Сообщение: Re: PreparedStatement syntax extensions?
Следующее
От: dexdyne
Дата:
Сообщение: Re: time zone setting.