[Pljava-dev] Notify/Listen

From: J(dot)Kraaijeveld at Askesis(dot)nl (Joost Kraaijeveld)
To:
Subject: [Pljava-dev] Notify/Listen
Date: 2006-08-13 12:13:48
Message-ID: 1155471228.5894.8.camel@panoramix
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pljava-dev

Hi John,

On Wed, 2006-08-09 at 12:08 -0400, Burtenshaw, John J. wrote:
>
> Has anyone ever used the Notify/Listen mechanism in pljava? How would
> you implement a client program that would do an sql Listen?
> Apparently according to the Postgresql docs there are functions that
> need to be called periodically to see if an event has occured or not
> (i.e. PQnotifies in libpq)
I do use notify/listen extensively thought not in pljava but in JBoss
using a MBean as a listener, which is polling in a separate thread. The
notify is done in a psql trigger. If you want I can send you the MBean
with the code, although it is very similar to the jdbc example here:
http://jdbc.postgresql.org/documentation/81/listennotify.html#listen-notify-example

--
Groeten,

Joost Kraaijeveld
Askesis B.V.
Molukkenstraat 14
6524NB Nijmegen
tel: 024-3888063 / 06-51855277
fax: 024-3608416
web: www.askesis.nl

In response to

Browse pljava-dev by date

  From Date Subject
Next Message Thomas Hallgren 2006-08-14 22:36:33 [Pljava-dev] Stack depth limit exceeded with pljava 1.2.0
Previous Message Burtenshaw, John J. 2006-08-09 16:08:39 [Pljava-dev] Notify/Listen