Skip to main content

Module server

Module server 

Source
Expand description

The live WebSocket cable server: an axum ws upgrade handler that speaks the ActionCable wire protocol, a ChannelRegistry routing subscriptions to Channel handlers, a heartbeat ping loop, and a pub/sub bridge so broadcasts reach subscribed clients.

Structs§

ChannelRegistry
Maps ActionCable channel names to their handlers, over a shared pub/sub backend (Rails’ channel routing).

Functions§

handle_socket
Drive a single upgraded WebSocket connection: greet with welcome, ping on a heartbeat, and dispatch inbound ActionCable frames until the socket closes.
route
A Router mounting the cable endpoint at /cable, backed by registry.
ws_handler
axum handler that upgrades a request to a cable WebSocket connection.