Skip to content

Networking Layer

Speed is nothing without a frictionless delivery mechanism. LoomCache handles inter-node communication and client-server traffic through a highly optimized TCP layer.

Rather than communicating via HTTP or REST JSON, LoomCache utilizes a hyper-efficient, custom binary protocol.

Wire Protocol Pipelining

Zero-copy serialization with batched pipelining over persistent TCP connections.

CLIENT
OP
BIN
OP
BIN
OP
BIN
SERVER
  1. Header Structure: Every packet has a fixed length header declaring the payload size, operation code (OP-Code), and a strict format.
  2. Zero-Copy Serialization: Map entries and keys are translated directly into byte streams, skipping object intermediary garbage collection where possible.
  3. Pipelining: Multiple commands can be flushed rapidly on the same connection, avoiding round-trip latency.

Networking logic is separated via specialized execution arenas:

  • CommandExecutorPool delegates non-I/O heavy state machine requests.
  • This prevents slow networks from backing up the core consensus algorithms.

Production deployments demand zero-trust encryption. LoomCache natively supports Mutual TLS (mTLS) for cluster inner-node communication. Each node validates the identity of adjoining nodes before participating in Raft elections or accepting writes.