Most IoT networks rely on centralized brokers. This creates a single point of failure and adds latency when devices only need to interact with their immediate physical surroundings. Synapse is an experimental project exploring a different approach. It replaces the centralized broker with a symmetric peer to peer mesh topology built on ZeroMQ.
The objective is to allow sensor nodes to ingest data and perform anomaly detection locally. The system uses the Uber H3 spatial index to group sensors by physical proximity. Nodes only subscribe to ZeroMQ topics corresponding to their own H3 cell and adjacent cells. When a node receives telemetry, it runs a leave one out statistical check against the active peers in the same geographic cell using Median Absolute Deviation. If a reading deviates significantly from the local median, the node flags the originating sensor as faulty and isolates it from further statistical calculations.
The system includes several operational mechanisms. Peer discovery uses mDNS and DNS Service Discovery for zero touch provisioning on local networks. Active connection management limits the maximum number of ZeroMQ sockets per node with dynamic failover, preventing CPU exhaustion on constrained hardware. For physical edge clusters, an official Helm chart deploys a DaemonSet topology with a Caddy sidecar for local TLS termination.
To validate the architecture, the project includes native benchmarking and chaos engineering tools. A simulated network of 50 nodes converges in under 3 seconds while processing approximately 2400 messages per second. Furthermore, a built in chaos tool integrates with Pumba to inject 200 milliseconds of latency and 15 percent packet loss directly into the containers via the Linux kernel traffic control. This allows operators to observe the dynamic self healing of the mesh under hostile network conditions.
Synapse remains a proof of concept designed to test specific distributed systems theories. The source code and documentation are open for review. Structural critique regarding the scalability of the mesh or the mathematical corroboration model is welcome.
Repo: https://github.com/onyks-os/Synapse
Documentation: https://onyks-os.github.io/synapse/