CatMQ v3.0.0
Downloads
CatMQ.linux.arm64.zip
60.00 MB · 2 downloads
CatMQ.linux.x64.zip
68.87 MB · 2 downloads
CatMQ.windows.x64.exe
14.07 MB · 1 downloads
NuGet packages: NTDLS.CatMQ.Client, NTDLS.CatMQ.Server and NTDLS.CatMQ.Shared (see all on NuGet).
Release notes
Full Changelog: https://github.com/NTDLS/CatMQ/compare/2.9.1...3.0.0
Be sure to check out the NuGet packages: 📦
https://www.nuget.org/packages/NTDLS.CatMQ.Shared
https://www.nuget.org/packages/NTDLS.CatMQ.Server
https://www.nuget.org/packages/NTDLS.CatMQ.Client
New 🎉
- HTTP API (
/api/v1) for managing queues and for publishing and consuming from any language, described by an OpenAPI document atdocs/api/catmq.openapi.yaml.- Create, read, update (
PATCH), list (paged), purge and delete queues, and redrive dead-letter queues. - Publish one message or a batch of up to 1,000, with per-message results.
- Idempotency keys: publishing the same key again within 24 hours returns the original message instead of adding a duplicate.
- Browse, read and delete messages without consuming them.
- List and remove consumers.
- Errors are RFC 9457 problem documents with a stable
code. - Authenticate with
Authorization: Bearerorx-catmq-api-key. The health check needs no key.
- Create, read, update (
- Leases: consumers ask for messages, waiting up to 60 seconds (long polling), and acknowledge each lease. The dispositions are consumed, notConsumed, notInterested, defer, deadLetter and drop. Leases can be extended and acknowledged in batches, and a lease that expires is delivered again.
- Webhooks: CatMQ POSTs each message to a URL, and the response status is the acknowledgment.
- Deliveries are signed with HMAC-SHA256, and secrets can be rotated with a 24-hour overlap.
- Each webhook can have its own timeout, maximum concurrency, custom headers and an enabled switch.
- Webhooks and their secrets survive restarts.
- Named consumers: a consumer is identified by a stable name instead of its connection. Consumers that share a name compete for messages. Lease consumers and webhooks stay registered across restarts.
- Language-neutral messages: a message has a message type, a content type, a body (JSON, text or base64 binary) and optional headers, so any language can publish and consume it.
CMqSerialization.RegisterMessageType<T>("orders.created")maps a .NET type to a neutral name in both directions.- Received messages expose
ContentType,Headers,BodyIsBase64,GetBodyBytes()andDeliveryAttempt.
- Python client (
clients/python): standard library only. It covers the whole API and includes a consume loop and webhook signature checking. - JavaScript/TypeScript client (
clients/javascript): no dependencies, with types included. It runs on Node.js 20 or later, Deno, Bun and browsers, and covers the same features as the Python client. - Shared conformance scenarios that both clients must pass, run against a real service as part of
dotnet test. - Samples for .NET over TCP, .NET over HTTP, Python and JavaScript. They all use the same queue and messages, so any publisher can feed any consumer.
- Queue depth limits (
MaxDepth). A full queue refuses messages with429 queue_fulland aRetry-Afterheader. - Configurable compression:
CompressionLevel(defaultFastest) andCompressionThreshold(default 1 KB) on both client and server. Each frame records how it was compressed, so the two sides don't need matching settings. - Settings in the service configuration and UI:
EnableWebApiandAllowHttpWebhooks.
Changed 😎
- Breaking: the old API and the UI's own controllers were replaced by the single
/api/v1API, which the web UI now uses as well. - Breaking: messages carry a message type name instead of an assembly-qualified type name. The raw
Enqueue/EnqueueExpedientoverloads now take(queueName, messageType, body, options), andCMqEnqueueOptionsaddsContentType,HeadersandBodyIsBase64. - Breaking: the wire format changed (new message fields and a compression marker byte), so clients and servers must both be 3.0.0.
- Breaking: removed the
NoDelaysetting from the client and server configuration. Nagle's algorithm is now always off. CreateQueue(configuration)now applies its settings to an existing queue instead of ignoring them.CreateQueue(name)still leaves an existing queue unchanged. A queue's persistence scheme cannot be changed.- Message delivery is transport-neutral: TCP subscribers, leases and webhooks all share the queue's
MaxOutstandingDeliveries. - Received JSON is deserialized case-insensitively, so camelCase properties from other languages fill PascalCase .NET properties.
- Updated NTDLS.ReliableMessaging to 4.0.1, which dispatches notifications in order and turns Nagle's algorithm off by default.
- The README now covers the HTTP API, the clients, webhooks and performance numbers.
Fixed 🐛
- Expedient publishes no longer arrive out of order. With ReliableMessaging 4.0.1, between a third and a half of them used to be reordered; none are now.
- Messages that no consumer needed anymore (for example, after every consumer had exhausted its delivery attempts) no longer stay stuck in the queue.
- Removed a race in the webhook retry test, and resolved all 131 xUnit analyzer warnings in the test project.