I’m using Pusher to Push events to my subscribed browsers.
When I send an update to my server, my server sends a Push event out, and my client (which originated the request) and any other clients that are subscribed are triggered.
The problem I have is the client where the event originated also gets the Pushed event.
Is there a way of identifying which client initiated the Push event? or preventing the originating client from either receiving the Push or at least querying the event for signs of the originator??
Found this article in the docs that explains how to exclude recipients.
http://pusher.com/docs/server_api_guide/server_excluding_recipients
Do this
To get the SocketId of the current connection. Then send it to the server as part of your JSON data.
Then after your server is finished computing whatever it needs to and is ready to trigger the PUSH event add the SocketId to the PUSH request.