aimdb-ws-protocol 0.1.0

Shared wire protocol types for AimDB WebSocket connector and clients
Documentation
  • Coverage
  • 68.42%
    39 out of 57 items documented0 out of 7 items with examples
  • Size
  • Source code size: 17.87 kB This is the summed size of all the files inside the crates.io package for this release.
  • Documentation size: 3.27 MB This is the summed size of all files generated by rustdoc for all configured targets
  • Ø build duration
  • this release: 31s Average build duration of successful builds.
  • all releases: 31s Average build duration of successful builds in releases after 2024-10-23.
  • Links
  • crates.io
  • Dependencies
  • Versions
  • Owners
  • lxsaah

aimdb-ws-protocol

Shared wire protocol types for the AimDB WebSocket connector ecosystem.

Used by:

  • aimdb-websocket-connector — the server side (Axum/Tokio)
  • aimdb-wasm-adapter — the browser client (WsBridge)

Wire Protocol

All messages are JSON-encoded with a "type" discriminant tag:

Server → Client ([ServerMessage])

  • data — live record push with timestamp
  • snapshot — late-join current value
  • subscribed — subscription acknowledgement
  • error — per-operation error
  • pong — response to client ping
  • query_result — response to a client query request

Client → Server ([ClientMessage])

  • subscribe — subscribe to one or more topics (supports MQTT wildcards)
  • unsubscribe — cancel subscriptions
  • write — inbound value for a link_from("ws://…") record
  • ping — keepalive ping
  • query — query historical / persisted records

Topic Matching

[topic_matches] implements MQTT-style wildcard matching (# for multi-level, * for single-level).