Struct djinn::WebSocketServer
[−]
[src]
pub struct WebSocketServer { /* fields omitted */ }
A WebSocket server which receives and publishes events.
Methods
impl WebSocketServer
[src]
fn new(addr: &str, redis_addr: &str) -> WebSocketServer
fn start(&mut self)
Runs a WebSocket server that subscribes to a Redis pubsub channel. Workers can publish messages to the channel and this server will forward them to connected WebSocket clients.
fn shutdown(self)
Shutdown the websocket server.