Sign inSign up

flez71/tinymq

By flez71

•Updated 2 months ago

A tiny, ultra-lightweight message broker for side projects, prototypes, and internal tools.

Image
Networking
Message queues
Developer tools
0

8.8K

flez71/tinymq repository overview

⁠🍃 TinyMQ

Go Version Release Docker Image Size License

A tiny, ultra-lightweight message broker for side projects, prototypes, and internal tools.
Built from scratch in Go with zero external heavy dependencies.

TinyMQ offers a true "plug & play" alternative to heavy brokers like RabbitMQ or Kafka. No complex clusters, no Erlang, no JVM — just a single Dockerized binary with built-in disk persistence, strict FIFO delivery, wildcard routing, a simple HTTP API, and now native multi-node clustering.

⁠Key Features

FeatureDescription
Zero DependenciesPure Go implementation under ~15MB. Extremely low RAM and CPU footprint.
Consumer Groups (Pub/Sub)Multiple microservices can read the same event stream independently via Virtual Topic Binding (?group=name) without competing for payloads.
Native WebSocketsFull-duplex TCP connections (/ws) for sub-millisecond, bi-directional publishing and subscribing.
Native MQTT (IoT)Native v3.1.1 gateway on port 1883. Seamlessly routes binary IoT data to HTTP/WS clients and back.
Native Clustering (HA)Built-in zero-dependency P2P clustering with automatic leader election, quorum-based replication, and transparent follower proxying.
Smart Disk Persistence & GCAppend-only Write-Ahead Log (.log) architecture with a background Auto-Compactor (Garbage Collector) to prevent infinite disk growth.
Strict Durability (FSync)Configurable bank-grade physical disk flushing after every operation to protect against sudden power loss.
Live Streaming (SSE)Real-time, non-destructive topic monitoring (GET /stream) utilizing native Server-Sent Events.
Dead Letter Queues (DLQ)Automatically isolates "poison pill" messages after 3 failed retries to keep your main pipelines flowing.
Time-Based RoutingSchedule delayed messages for the future or set expiration times natively (TTL & Delays).
Network IdempotencyCaches Idempotency-Key headers to safely ignore duplicate publish requests caused by network retries.
Batching & PrefetchPull multiple messages in a single HTTP call (?limit=X) to drastically reduce network overhead.
Push Consumers (Webhooks)Passive integration. Let the broker POST directly to your external endpoints with built-in SSRF protection.
Native ObservabilityBuilt-in /metrics endpoint formatted natively for Prometheus scraping, requiring zero external agents.
Interactive UI & CLIBuilt-in web Dashboard to monitor queues visually, and a native terminal CLI (tmq) for management, offline backups, and high-concurrency stress testing (bench).
Graceful ShutdownSafely flushes OS-level buffers to disk on SIGTERM/SIGINT to prevent data loss.
Plug & Play ConfigurationAuto-loads .env files dynamically. No complex XML/YAML configuration files required.

⁠More Info

This is just the quick reference. For the full API documentation, SDK usage, environment variable list, and issue tracking, please visit our official GitHub repository and documentation website:

Tag summary

Content type

Image

Digest

sha256:3da1611fc…

Size

3.9 MB

Last updated

2 months ago

docker pull flez71/tinymq