Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

[JDBC] PATCH: Update LISTEN/NOTIFY documentation, PGConnection JavaDoc

20 views
Skip to first unread message

Craig Ringer

unread,
Dec 11, 2009, 10:52:42 AM12/11/09
to
Hi folks

It seems the JDBC driver no longer requires a query to be issued before
it will notice new notify messages and be able to process them via
getNotifications() . The JDBC driver documentation doesn't reflect this.

I've attached a patch that updates the documentation. It includes one
thing I'm not 100% sure of, though:

- It states that the need for a dummy query was removed in the 8.1
driver, but I'm not sure that it was in fact 8.1 (and have no idea what
the build number was). Before I went CVS-history-diving I thought I'd
ask and see if anybody knew when the change was.

In addition to correcting the confusion, I've added @see links to the Pg
LISTEN/NOTIFY docs, added a note about older versions requiring a dummy
select, noted that calling getNotifications() doesn't create network
traffic, and fixed an unrelated place where "8.1" should've read "8.1 or
later".

--
Craig Ringer

PgJDBC-notify.diff

Craig Ringer

unread,
Dec 18, 2009, 10:19:10 AM12/18/09
to
On 11/12/2009 11:52 PM, Craig Ringer wrote:
> Hi folks
>
> It seems the JDBC driver no longer requires a query to be issued before
> it will notice new notify messages and be able to process them via
> getNotifications() . The JDBC driver documentation doesn't reflect this.

Argh!

It's very dependent on the underlying socket, and in particular doesn't
seem to work for Java's SSL sockets.

Sigh. I can have security OR low-overhead timely notifications.

--
Craig Ringer

--
Sent via pgsql-jdbc mailing list (pgsql...@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-jdbc

0 new messages