Expand description
Per-endpoint handle store and body channel types.
Rust owns all stream state; JS holds only opaque u64 handles.
Each IrohEndpoint has its own HandleStore — no process-global registries.
Handles are u64 values equal to key.data().as_ffi(), unique within the
owning endpoint’s slot-map.
Structs§
- Body
Reader - Consumer end — stored in the reader registry.
Uses
tokio::sync::Mutexso we can.awaitthe receiver without holding the registry’sstd::sync::Mutex. - Body
Writer - Producer end — stored in the writer registry.
mpsc::SenderisClone, so we clone it out of the registry for each call. - Handle
Store - Per-endpoint handle registry. Owns all body readers, writers, trailers,
sessions, request-head rendezvous channels, and fetch-cancel tokens for
a single
IrohEndpoint. - Response
Head Entry - Session
Entry - Store
Config - Configuration for a
HandleStore. Set once at endpoint bind time.
Constants§
- DEFAULT_
CHANNEL_ CAPACITY - DEFAULT_
DRAIN_ TIMEOUT_ MS - DEFAULT_
MAX_ CHUNK_ SIZE - DEFAULT_
MAX_ HANDLES - DEFAULT_
SLAB_ TTL_ MS
Functions§
- make_
body_ channel - Create a matched (writer, reader) pair backed by a bounded mpsc channel.