netbaiot-protocol
Public wire and domain types, stable errors, paths, and protocol version 1
Architecture
Normal MQTT and TCP telemetry uses socket parser state, a bound AuthContext, shared codec/config snapshots, and bounded memory routing. It performs no database, filesystem, remote auth, or control-plane operation on the hot path.
HTTP / MQTT / TCP / UDP devices
|
v
transport framing and lifecycle
|
v
authentication / ACL / bound AuthContext
|
v
versioned DeviceCodec
|
v
DeviceEvent(event_id)
|
v
bounded EventBus and atomic required-sink admission
|
+------ confirmed HTTP webhook
|
+------ confirmed framed TCP/RPC streamPublic client crates depend only on netbaiot-protocol and network libraries. They never depend on runtime, transport, broker, session, or server implementation crates.
Public wire and domain types, stable errors, paths, and protocol version 1
Business HTTP APIs and confirmed event-stream ownership
Optional standard MQTT 3.1.1 and device HTTP convenience client
Domain types and the synchronous DeviceCodec trait
Bounded vendor and device protocol codecs
Caches, admission, EventBus, sessions, commands, metrics, and restart spool
HTTP, embedded MQTT 3.1.1, framed TCP, UDP, ACLs, and connection owners
Validated composition, business sinks, listeners, recovery, and graceful shutdown
Operator interface implemented only through netbaiot-client
The broker implements CONNECT through DISCONNECT, including QoS0, QoS1, and explicit QoS2 state machines. ClientId is not trusted identity. Persistent sessions are keyed by authenticated DeviceKey plus ClientId. MQTT QoS and EventBus delivery are separate contracts.
v1/t/{tenant}/p/{product}/d/{device}/up
v1/t/{tenant}/p/{product}/d/{device}/up_ack
v1/t/{tenant}/p/{product}/d/{device}/down
v1/t/{tenant}/p/{product}/d/{device}/down_ackThere is deliberately no storage crate, SQL migration, database pool, durable outbox, persistent command state, or runtime message history. Business systems own durable business data.