softwaremill/kmq
56.0
Adequate · 20 September 2026
1.4k
lines of production code
Java
with Scala
1
measurement over time
What this system is
This system is a Kafka message queue library (kmq) that provides selective acknowledgment and robust redelivery mechanisms for message processing. It replaces previous Kafka Streams dependencies with a lightweight, Cats Effect-based architecture that tracks message delivery via markers and headers. The library supports configurable retry limits, dead-letter queues for failed messages, and isolated thread pools for redelivery operations to ensure resource safety and predictable message lifecycles.
Features
Added standalone Scala example application
A new standalone example application has been added to demonstrate the KMQ library's functionality. It includes a reactive client that consumes messages from a Kafka topic, sends start and end markers for tracking, and conditionally processes or drops messages. The example also provides a sender component that generates and publishes test messages, and a tracker component for monitoring redelivery status.
example-scala/src/main/scala · high confidence
Added standalone example application components
The standalone example directory now includes configuration, sender, processor, and redelivery tracker classes that demonstrate how to use the KMQ library. Users can now run a complete message queue workflow locally, including sending messages, processing them with configurable timeouts, and tracking redeliveries, with optional SSL configuration examples provided in comments.
example-java/src/main/java/com/softwaremill/kmq/example/standalone · high confidence
Initial project scaffolding and configuration
The repository is initialized with core configuration files including an Apache 2.0 license, a README documenting the Kafka message queue library (kmq) and its selective acknowledgment mechanism, and build tooling settings. Specifically, \.scalafmt.conf\ sets the formatting dialect to Scala 3 with version 3.7.3, \.scala-steward.conf\ configures dependency updates, and \.mergify.yml\ defines automated merge rules for CI checks. The \.gitignore\ is updated to exclude IDE-specific files like \.bsp\, \.bloop\, and \metals.sbt\.
(repo-wide) · high confidence
New embedded Kafka example with configurable redelivery and uncaught exception handling
The embedded example now includes a new \UncaughtExceptionHandling\ utility that sets a default uncaught exception handler for logging thread errors. The \EmbeddedExample\ demonstrates an iterative client pattern where message processing uses a configurable redelivery tracker based on message timestamps rather than processing timestamps. The example configures a 10-second timeout for redelivery and processes messages in background threads, simulating failures by randomly dropping 10% of messages to trigger redelivery.
example-java/src/main/java/com/softwaremill/kmq/example/embedded · high confidence
Removals
Removal of Kafka Streams-based redelivery and example application
The \App.java\ entry point, which demonstrated a basic message queue using embedded Kafka, has been removed. Additionally, the \RedeliveryProcessor\ and \RedeliveryTracker\ classes, which implemented a Kafka Streams topology for tracking and redelivering timed-out messages, have been deleted. This change removes the existing redelivery mechanism and the associated example code from the main source tree.
src/main · high confidence
Behavioural changes
New dedicated dispatcher for redeliverers
A new configuration entry \kmq.redeliver-dispatcher\ has been added to the reference configuration, defining a dedicated thread-pool-executor for redeliverers. This change allows redelivery operations to be isolated on their own thread pool, potentially improving performance and resource management for message redelivery tasks.
core/src/main/resources · medium confidence
Redelivery subsystem refactored to use Cats Effect
The redelivery mechanism in the core module has been reimplemented to replace the previous Akka-based actors with a Cats Effect-based architecture. This change introduces new components in the redelivery package, including \KafkaClientsResourceHelpers\ for managing Kafka producer and consumer resources, \RedeliveryActors\ for starting the redelivery process, and a \package.scala\ defining core type aliases. The implementation now relies on \cats.effect.IO\ and \Resource\ for resource safety, marking a shift from the prior actor model to a functional effect system.
core/src/main/scala · high confidence
Refactored redelivery mechanism and core configuration
The redelivery system has been reimplemented to use message timestamps instead of processing timestamps and no longer relies on Kafka Streams or an additional topic, simplifying the infrastructure requirements. A new \KmqConfig\ class centralizes configuration, allowing users to parametrize the dead-letter queue name, maximum redelivery count, and redelivery count header. The \MarkerValue\ type is now an interface with distinct \StartMarker\ and \EndMarker\ implementations, improving type safety for offset tracking. Additionally, \KafkaClients\ has been refactored from a static utility to an instance-based class that supports global extra configuration and explicit consumer group IDs, while removing embedded Kafka dependencies.
core/src/main/java · high confidence
Reimplemented message redelivery with configurable dead-letter queue and retry limits
The library now uses a marker-based redelivery mechanism (replacing the previous Kafka Streams approach) to handle undelivered messages. When a message exceeds the configured maximum redelivery count, it is automatically sent to a configurable dead-letter topic instead of being retried indefinitely. The system tracks redelivery attempts via a header and supports parameterized redelivery timeouts and retry counts, ensuring messages are only redelivered after the queue state is recovered and providing better control over message processing lifecycles.
repository · high confidence
Test coverage
Added tests for message redelivery and dead-letter queue behavior
Added integration and unit tests in core/src/test to verify the redelivery mechanism, including sending undelivered messages to a dead-letter queue, respecting maximum redelivery counts, and properly sorting markers in the queue.
core/src/test · high confidence
Dependencies
Update project dependencies and build configuration
The build configuration has been updated to use Scala 2.13.16 and upgraded several key libraries: Kafka clients to 3.4.0, Cats Effect to 3.4.9, fs2 to 3.6.1, log4cats to 2.6.0, and ScalaTest to 3.2.15. Additionally, the build now includes Akka Stream Kafka 2.1.1 for the example Scala module and configures test execution settings to disable parallelism and limit concurrent tests.
(dependencies) · high confidence
Written by watchdog.canine.dev from the codebase's own history, inside the signed delivery this page is composed from.
How this codebase got here
Baseline
- First survey — no prior run to compare against. CAI 56.
Lenses
- Code Health 97
- Architecture 69
- Maturity 45
- Readiness 64
- Security 61
Changes since last survey
- 189 commits — 181 feature/other, 8 fixes
By area
- core/src — 69 commits
- (root) — 58 commits
- (repo) — 22 commits
- src/main — 12 commits
- example-java/src — 11 commits
- project/plugins.sbt — 9 commits
- .github/workflows — 5 commits
- core/pom.xml — 1 commit
- example-scala/pom.xml — 1 commit
- example-scala/src — 1 commit
Notable commits
- fix: CI - fix mima settings
- fix: CI - fix scala steward
- fix: Fix releasing from root
- fix: Fixes
- fix: Merge pull request #159 from softwaremill/fix-endoffsets-map-lookup
- fix: after review: fix deprecation warning
- fix: fix compile errors
- fix: fix compile errors for scala2_13
- change: 0.1 release
- change: 0.2 release
- change: 0.2.1 release
- change: Add 'Reformat with scalafmt 3.5.9' to .git-blame-ignore-revs
- change: Add 'Reformat with scalafmt 3.7.3' to .git-blame-ignore-revs
- change: Add Gitter badge
- change: Add global extraConfig parameter to KafkaClients
- change: Add image
- change: Add missing plugin
- change: Adding a close method to kmq client
- change: Adding logging to scala example
- change: Additional test
- …and 169 more
Architecture
- 0 containers · 1 bounded contexts · 0 dependency edges (baseline)
Written by watchdog.canine.dev from the codebase's own history, inside the signed delivery this page is composed from.
Survey your own repository
softwaremill/kmq was measured the same way every project in this corpus was: the same rubric, at a pinned commit, with the result published in full. Point a surveyor at a repository you know and see whether you agree with it.
About this page
- The score is its most recent published measurement, taken on 20 September 2026 at a pinned commit. It is not a live figure and does not change until the project is measured again.
- Measured at commit bb0a6bf0d49011cfd58dca757e3e837522144750 — the exact code this score is about.
- Scored under rubric-2026.09.15 — the same rubric and the same method as every other entry in this index.
- Measured by watchdog.canine.dev using codehealth-analyzer preprod-b51f968c9b10.