Accepts messages from external sources. Associated with a core. Sends incoming events to the core’s streams, queries the core’s index for states.
Converts a URL query string into a map.
(input-event! core stats event)
(put-events-handler core stats ch req)
Accepts events from the body of an HTTP request as JSON objects, one per line, and applies them to streams.
(ws-handler core stats)
(ws-index-handler core stats ch hs actions)
Queries the index for events and streams them to the client. If subscribe is true, also initiates a pubsub subscription to the index topic with that query.
(ws-pubsub-handler core stats ch hs actions)
Subscribes to a pubsub channel and streams events back over the WS conn.
Starts a new websocket server for a core. Starts immediately.
- :host The address to listen on (default 127.0.0.1)
- :port The port to listen on (default 5556)