Integrant wiring for the realtime module.
Config key: :wagoe/realtime {:provider :in-memory | :redis ;; redis only: :host "localhost" :port 6379 :password "..." :database 0 ; auth + db selection (production) :timeout 2000 ; socket timeout ms :max-total 8 :max-idle 8 :min-idle 0 ; publish-pool sizing :channel "wagoe:realtime:bus" :key-prefix "realtime" :subscribe-timeout-ms 5000 ; await window for subscription to go live :jwt-verifier <IJWTVerifier ref>}
The local connection registry is in-memory under BOTH providers (sockets are node-local). Only the pub/sub manager and the bus differ. Under :redis the component opens two Jedis pools — one for topic subscriptions (pub/sub manager) and one inside the bus for publish — both closed on halt.
IMPORTANT: the web/WS server component MUST depend on :wagoe/realtime so that start-subscriber! has completed (subscription live) before any WebSocket connection is accepted.
Integrant wiring for the realtime module.
Config key: :wagoe/realtime
{:provider :in-memory | :redis
;; redis only:
:host "localhost" :port 6379
:password "..." :database 0 ; auth + db selection (production)
:timeout 2000 ; socket timeout ms
:max-total 8 :max-idle 8 :min-idle 0 ; publish-pool sizing
:channel "wagoe:realtime:bus"
:key-prefix "realtime"
:subscribe-timeout-ms 5000 ; await window for subscription to go live
:jwt-verifier <IJWTVerifier ref>}
The local connection registry is in-memory under BOTH providers (sockets are
node-local). Only the pub/sub manager and the bus differ. Under :redis the
component opens two Jedis pools — one for topic subscriptions (pub/sub
manager) and one inside the bus for publish — both closed on halt.
IMPORTANT: the web/WS server component MUST depend on :wagoe/realtime so
that start-subscriber! has completed (subscription live) before any WebSocket
connection is accepted.No vars found in this namespace.
cljdoc builds & hosts documentation for Clojure/Script libraries
| Ctrl+k | Jump to recent docs |
| ← | Move to previous article |
| → | Move to next article |
| Ctrl+/ | Jump to the search field |