JWT verification adapter that delegates to boundary/user module.
Wraps boundary.user.shell.auth/validate-jwt-token to provide IJWTVerifier protocol implementation. Avoids direct dependency from core layer to user module.
Responsibilities (Shell/I/O):
JWT verification adapter that delegates to boundary/user module. Wraps boundary.user.shell.auth/validate-jwt-token to provide IJWTVerifier protocol implementation. Avoids direct dependency from core layer to user module. Responsibilities (Shell/I/O): - Call user module for JWT verification (I/O - external dependency) - Transform user module response to expected format - Handle verification errors
WebSocket connection adapter for Ring/Jetty.
Wraps Ring WebSocket implementation to provide IWebSocketConnection protocol. Handles JSON encoding/decoding and WebSocket frame transmission.
Responsibilities (Shell/I/O):
WebSocket connection adapter for Ring/Jetty. Wraps Ring WebSocket implementation to provide IWebSocketConnection protocol. Handles JSON encoding/decoding and WebSocket frame transmission. Responsibilities (Shell/I/O): - Send messages over WebSocket (I/O operation) - Close WebSocket connections (I/O operation) - JSON encoding (external format transformation) - Error handling and logging
In-memory connection registry implementation.
Stores active WebSocket connections in an atom for single-server deployments. For multi-server scaling, swap with Redis-backed registry implementation.
Registry Structure: {connection-id {:connection <Connection record> :ws-adapter <IWebSocketConnection>}}
Responsibilities (Shell/I/O):
In-memory connection registry implementation.
Stores active WebSocket connections in an atom for single-server deployments.
For multi-server scaling, swap with Redis-backed registry implementation.
Registry Structure:
{connection-id {:connection <Connection record>
:ws-adapter <IWebSocketConnection>}}
Responsibilities (Shell/I/O):
- Store and retrieve connection mappings (stateful atom)
- Filter connections by user-id, role (uses core filtering functions)
- Thread-safe updates (atom swap operations)In-memory pub/sub topic management (imperative shell).
Implements IPubSubManager protocol using atom-based subscription storage. Coordinates between pure pub/sub core functions and stateful subscription management.
Single-server implementation - subscriptions stored in memory. For multi-server deployments, would need Redis-backed implementation (v0.2.0).
Thread-safe via atom swap operations.
In-memory pub/sub topic management (imperative shell). Implements IPubSubManager protocol using atom-based subscription storage. Coordinates between pure pub/sub core functions and stateful subscription management. Single-server implementation - subscriptions stored in memory. For multi-server deployments, would need Redis-backed implementation (v0.2.0). Thread-safe via atom swap operations.
Realtime service implementation (Shell layer).
Orchestrates WebSocket messaging between core logic and adapters. Implements the imperative shell in the FC/IS architecture pattern.
Responsibilities (Shell/I/O):
Does NOT contain:
Realtime service implementation (Shell layer). Orchestrates WebSocket messaging between core logic and adapters. Implements the imperative shell in the FC/IS architecture pattern. Responsibilities (Shell/I/O): - WebSocket connection lifecycle (open, close) - JWT authentication (delegates to user module) - Message routing (uses core routing logic) - Connection registry management - Pub/sub topic management - Logging and error handling Does NOT contain: - Business logic (lives in core.*) - Database operations (no persistence needed for WebSockets) - Message validation logic (lives in core.message)
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 |