@echelon-framework/transport-ws
v0.7.1
Published
WebSocket TransportAdapter dla Echelon — reaktywne streamy z auto-reconnect.
Maintainers
Readme
@echelon-framework/transport-ws
WebSocket TransportAdapter for Echelon framework — auto-reconnect, heartbeat, message routing.
Part of the Echelon Framework — Angular-based, config-driven dashboard & low-code platform.
Installation
npm install @echelon-framework/transport-wsUsage
import { WsTransportAdapter } from '@echelon-framework/transport-ws';
// WebSocket streams registered in provideEchelon
provideEchelon({
streams: {
'rates.usdpln': { url: 'wss://feed.example.com/fx/usdpln' },
positions: { url: 'wss://feed.example.com/positions' },
},
});Features
- Auto-reconnect — exponential backoff (1s, 2s, 4s, 8s, max 30s)
- Heartbeat — configurable ping/pong interval
- Message routing — channel-based message dispatch to DataBus
- Binary support — ArrayBuffer and Blob messages
- Connection state — observable connection status (connecting/open/closed/error)
Configuration
WsTransportAdapter.create({
url: 'wss://feed.example.com',
reconnectMaxRetries: 10,
heartbeatIntervalMs: 30000,
protocols: ['echelon-v1'],
});License
BUSL-1.1
