Skip to content

ProtoMQ: Type-safe, bandwidth-efficient MQTT for the rest of us. Stop sending bloated JSON over the wire.

License

Notifications You must be signed in to change notification settings

electricalgorithm/protomq

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

8 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

ProtoMQ

ProtoMQ Mascot
Type-safe, bandwidth-efficient MQTT for the rest of us.
Stop sending bloated JSON over the wire.


  • MQTT v3.1.1 packet parsing (CONNECT, PUBLISH, SUBSCRIBE, etc.)
  • Thread-safe Topic Broker with wildcard support (+, #)
  • Custom Protobuf Engine with runtime .proto schema parsing
  • Topic-based Protobuf schema routing
  • MQTT CLI client with automatic JSON-to-Protobuf encoding
  • Structured diagnostic output for Protobuf payloads

Building

One have to have Zig 0.15.2 or later installed. Please download it from here.

# Build server and client
zig build

# Build and run server
zig build run-server

# Build and run client
zig build run-client

# Run tests
zig build test

# Run integration tests
zig build && \
./tests/cli_test.sh && \
./tests/integration_test.sh && \
./tests/run_pubsub_test.sh

Limitations

For the initial release, we support:

  • QoS 0 only (at most once delivery)
  • No persistent sessions
  • No retained messages
  • Single-node deployment

Performance Results

Verified metrics with 100 concurrent clients on Apple M2 Pro (macOS) and Raspberry Pi 5 (Linux):

  • Concurrency: 100+ concurrent connections verified.
  • Latency (p99): < 0.3ms (Measured 0.24ms for MacOS and 0.17ms for Linux).
  • Memory Footprint: < 2.4 MB for 100 clients (Measured 2.41 MB for MacOS and 2.00 MB for Linux).

For detailed methodology and full results, see RESULTS.md.

Contributing

This is currently a learning/development project. Contributions will be welcome after the MVP is complete.

License

The project is licensed under the MIT License - see the LICENSE file for details.

Resources


Note: This project is under active development. The API and architecture may change significantly.

About

ProtoMQ: Type-safe, bandwidth-efficient MQTT for the rest of us. Stop sending bloated JSON over the wire.

Topics

Resources

License

Stars

Watchers

Forks