0

I have a written function that it's last row is:

Notify ALLOCWARE;

I know that this is a message via some sort of channel. Where I can find which function is triggered due to this command?

4
  • No "function" is triggered. Any session that registered itself as a listeren will be notified. Commented Apr 25, 2017 at 7:29
  • @a_horse_with_no_name That I know.. but where I can see who listen to that? I'm debugging the code and i'm stuck due to this Commented Apr 25, 2017 at 7:31
  • stackoverflow.com/questions/29623503/… Commented Apr 25, 2017 at 7:55
  • @pozs pg_listening_channels shows channels, that current_session listens to, while OP wants to list sessions that listen to his channel Commented Apr 25, 2017 at 7:56

1 Answer 1

1

The list of channels on which a given session is listening is stored in the backend's private memory (listenChannels in src/backend/commands/async.c), so there is no way to figure out on which channels other sessions are listening.

Sign up to request clarification or add additional context in comments.

7 Comments

sessions only communicate with the server, not with each other. This notify trigger some action from the server but I can't figure out which.
That depends on what API you are using.
How do I know that? I'm using PostgreSQL 9.3
Meh. But how do you use it? On the command line or from a program? In which programming language is the program that accesses PostgreSQL written, and which library does it use to access PostgreSQL?
I don't know. This is a code written by someone who is not here anymore.. If there is a way to check please let me know how. This is why i'm lost. I can't figure out who and where it's handled.
|

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.