Expand description
§sioc
A type-safe, async Socket.IO protocol v5 client for Rust.
§What is the Socket.IO protocol?
The Socket.IO protocol v5 is built on top of Engine.IO protocol v4.
It adds namespaces for multiple channels over a single connection, events as named messages with structured data, acknowledgements for request/response patterns, and support for binary attachments.
§Design
- Async networking built on
tokio,reqwest, andtokio-tungstenite. - Actor-model client, communicating through channels, no internal locks.
- Derive macros for events and acks.
- Event handling lives in match arms, no callbacks with boxed futures.
- State lives in the enclosing scope, no Arc or Mutex.
- Zero-copy packet parsing via
bytestringandbytes.
§License
MIT OR Apache-2.0.
Modules§
- ack
- Typed Socket.IO acknowledgements (request/response over events).
- binary
- Binary attachment support for Socket.IO events and acknowledgements.
- client
- Socket.IO client and namespace handles.
- error
- Error types for the
sioccrate. - event
- Typed Socket.IO events: the primary way to send and receive data.
- manager
- Socket.IO namespace router.
- marker
- Compile-time markers that encode whether a packet carries binary attachments and/or expects an acknowledgement.
- packet
- Socket.IO v4 packet types and wire encoding.
- payload
- Payload serialization and deserialization traits and helpers.
- prelude
- Convenience re-exports for common usage.