Re: [OT] Dilemma about OS <-> Postgres interaction

From: Karsten Hilbert <Karsten(dot)Hilbert(at)gmx(dot)net>
To: Postgresql General List <pgsql-general(at)postgresql(dot)org>
Subject: Re: [OT] Dilemma about OS <-> Postgres interaction
Date: 2004-06-17 22:07:55
Message-ID: 20040618000755.E743@hermes.hilbert.loc
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

> I suppose I could use plperl and create a trigger to alert a system-wide
> daemon that a message was ready for sending whenever a new one dropped
> into the 'outbox', and restart the daemon if it had died. I feel
> superstitious about using an untrusted language for functions though.
Sounds like a perfect candidate for a notify/listen solution ?

Eg. send a notify from an insert trigger. In your "listen"
listener loop in the demon regularly check and re-establish
the database connection.

In GnuMed we are listening for trigger()ed notifies on
insert/delete/upgrade in our middleware cache quite
successfully.

Karsten
--
GPG key ID E4071346 @ wwwkeys.pgp.net
E167 67FD A291 2BEA 73BD 4537 78B9 A9F9 E407 1346

In response to

Browse pgsql-general by date

  From Date Subject
Next Message Edmund Bacon 2004-06-17 22:30:04 Re: [OT] Dilemma about OS <-> Postgres interaction
Previous Message Carl Anderson 2004-06-17 22:07:05 Postgres "invalid page header"