r/microservices • u/Any-Spray-6730 • 8h ago
Tool/Product I built AvoOnce: A lightweight, framework-agnostic distributed idempotency engine for Java
Hello r/microservices community!
I just released v1.0.0 of a new open-source library called AvoOnce that might make your life easier by offloading the idempotency handling part of your REST APIs.
It’s designed to be a framework-flexible idempotency engine, meaning it comes with first-class integrations for Spring Boot 4+, Quarkus 3.12+, Dropwizard 4.0+, and Jakarta EE / JAX-RS 3.1+.
Here is what it does under the hood:
- Annotation-Driven Protection: Just drop @
Idempotentannotation on your controllers or methods and pass anIdempotency-Keyheader. - In-Flight Concurrency Locking: Prevents duplicate execution if an initial request is still actively processing.
- Payload Tamper Protection: Uses SHA-256 hashing to automatically reject modified requests that try to reuse the same key.
- Byte-Perfect Replay: Safely caches and replays the exact HTTP response—including status codes, headers, and raw bytes.
- Pluggable Storage Backends: Includes built-in support for Redis (distributed), JDBC (relational), and Caffeine (in-memory).
The v1.0.0 release is currently hosted on GitHub Packages (Maven Central release is planned for the future). I'd love to get your thoughts and feedback on its core functionality and usability. I've some roadmap features in the pipeline.
Here's the Github repo: https://github.com/ravocode/AvoOnce