Function StackSSE
Register SSE
Registers an SSEController to a specific channel name in a global SSEPublisher.
This allows the server to send messages to all clients subscribed to the same channel.
Config
-
SSE Controller
An instance ofSSEControllerthat manages the upgraded SSE connection. -
Channel Name
The name of the channel to associate the controller with. Clients registered under the same channel will receive published events. -
Publisher
An instance ofSSEPublisher, which should be created once globally to handle broadcasting events to multiple clients.
Please create and start the SSEPublisher once using a server hook when the server starts.
You can access it later using the Get Registry Value function.
For a detailed usage example, check the Publish SSE function.
