Re: Use LISTEN/NOTIFY between different databases - Mailing list pgsql-general

From Igor
Subject Re: Use LISTEN/NOTIFY between different databases
Date
Msg-id CALdM5eopyKf-wJLqLuyLwbV6pG2H_YnHFR1a1wRu5Jqr6waZzg@mail.gmail.com
Whole thread Raw
In response to Re: Use LISTEN/NOTIFY between different databases  (John R Pierce <pierce@hogranch.com>)
Responses Re: Use LISTEN/NOTIFY between different databases
List pgsql-general

Its real situation. We use sharded cluster based on plproxy. The calling function for DB queries is equal in all databases (see plproxy documentation). Now we need to release some internal logic between clients based on certain events which occurred in this functions. The LISTEN/NOTIFY mechanism is very good feature, but event occur NOT in connected DB - i.e. in destination DB via plproxy wrapper. I.e. wee need subject.

then maybe you could have a process to do this work which connects to all the databases and issues the LISTENs and initiates whatever actions you need in the other database(s) ?



Yes, but it is workaround. The native way - is the "communication" on  DB-backend level.
It would be very good feature - possibility to set a destination DB in NOTIFY command as optional argument.

Is the developers read this list ? :)


--
john r pierce                            N 37, W 122
santa cruz ca                         mid-left coast



--
Regards

pgsql-general by date:

Previous
From: "Albe Laurenz"
Date:
Subject: Re: Difference between speed of 2 functions: SQL+STABLE and PLPGSQL+EXECUTE
Next
From: Clemens Eisserer
Date:
Subject: Re: Is there a tool for checking database integrity