PusherPubSubIncomingMessageHandler
class PusherPubSubIncomingMessageHandler implements PubSubIncomingMessageHandler
Properties
| protected array<string, list<callable>> | $events | Registered event listeners. |
Methods
Handle an incoming message from the pub/sub provider.
Handle a broadcast message from another node.
Handle a metrics request from another node.
Terminate all connections for the given user.
Resolve the application instance from an app ID.
Process the given event through registered listeners.
Listen for the given event.
Stop listening for the given event.
Details
at line 27
void
handle(string $payload)
Handle an incoming message from the pub/sub provider.
Uses scalar payloads — resolves Application from ApplicationProvider instead of unserializing objects.
at line 47
protected void
handleMessage(array $event)
Handle a broadcast message from another node.
at line 78
protected void
handleMetricsRequest(array $event)
Handle a metrics request from another node.
at line 95
protected void
handleTerminate(array $event)
Terminate all connections for the given user.
at line 110
protected Application
resolveApplication(string $appId)
Resolve the application instance from an app ID.
at line 118
protected void
processEventListeners(array $event)
Process the given event through registered listeners.
at line 132
void
listen(string $event, callable $callback)
Listen for the given event.
at line 140
void
stopListening(string $event)
Stop listening for the given event.