Expand description
Distributed serving infrastructure for Pictor.
Provides a consistent hash ring for request routing across multiple inference nodes, a node registry with health tracking, and a multi-node coordinator that manages cluster topology.
§Architecture
┌────────────────────────────────────────────┐
│ DistributedCoordinator │
│ ┌──────────────────────────────────────┐ │
│ │ NodeRegistry │ │
│ │ ┌────────────────────────────────┐ │ │
│ │ │ ConsistentHashRing │ │ │
│ │ │ [VNode, VNode, ..., VNode] │ │ │
│ │ └────────────────────────────────┘ │ │
│ │ HashMap<node_id, NodeInfo> │ │
│ └──────────────────────────────────────┘ │
└────────────────────────────────────────────┘The hash ring uses FNV-1a (64-bit) with virtual nodes for even distribution. All state is in-memory — no actual TCP connections are made.
Structs§
- Consistent
Hash Ring - Consistent hash ring with virtual nodes for even load distribution.
- Coordinator
Config - Configuration for a
DistributedCoordinatorinstance. - Distributed
Coordinator - In-memory multi-node coordinator.
- Node
Info - Runtime information about a single serving node.
- Node
Registry - Cluster membership store backed by a consistent hash ring.
- VNode
- A virtual node on the ring — maps a hash position to a backend node.
Functions§
- fnv1a_
hash - FNV-1a 64-bit hash — fast, good distribution, no external deps.