Repository navigation
Releases
Releases · mariotoffia/godynamodb-queue
v0.11.0
What's Changed
Deterministic HMAC Signing Key for Receipt Handle Verification
Previously, the HMAC signing key used for receipt handle verification was generated randomly per queue instance. This meant that if the queue instance was recreated (process restart, different consumer, scaling event), the new instance could not verify receipt handles signed by the previous instance, making message acknowledgment (delete) impossible.
Changes:
- Default signing key is now deterministic — receipt handles work across queue instances out of the box without any configuration
- Added
UseSigningKey(key []byte) Queueto theQueueinterface for providing a custom secret key (recommended for production) - Added
MinSigningKeyLengthconstant (32 bytes) andErrSigningKeyTooShortsentinel error - Key validation is deferred to operation time, consistent with existing
UseTable/UseQueueName/UseClientIDpattern
Usage with custom key:
queue := dynamodbqueue.New(cfg, 0).
UseTable("my-table").
UseQueueName("my-queue").
UseClientID("consumer-1").
UseSigningKey([]byte("your-32-byte-secret-key-here!!!!"))Other
- CI badge fix
- CI test configuration improvements
Full Changelog: v0.10.2...v0.11.0
v0.10.2 - Security Hardening & Test Improvements
What's Changed
Security Improvements
- HMAC-SHA256 receipt handle signing - Prevents tampering with receipt handles
- Message size validation - Enforces 256KB limit with clear error messages
- Deferred validation pattern - Configuration validated at operation time
Bug Fixes
- Fixed poll timeout semantics (
timeout=0no longer skips database queries) - Fixed test infrastructure for reliable Docker container cleanup
- Added signal handling (SIGINT/SIGTERM) for graceful test shutdown
Test Infrastructure
- Comprehensive test coverage for security and validation
- Context cancellation propagation tests
- Backoff strategy tests
- Improved CI workflows with golangci-lint configuration
Code Quality
- Split large files to improve maintainability (<500 LOC per file)
- Added
.golangci.ymlconfiguration
Full Changelog: v0.10.1...v0.10.2
v0.10.0 - Standard/FIFO Queue Modes with Race Condition Fix
Summary
- Refactored queue architecture into separate Standard and FIFO implementations
- Implemented race condition fix for FIFO queues with post-lock verification
- Added comprehensive test suite including race condition tests, benchmarks, and simulations
- Updated Makefile with separate
test(unit only) andtest-ci(integration) targets - Removed runtime-alterable
SetRandomDigits- now constructor-only with minimum 8 digits - Fixed test infrastructure with proper container cleanup and DB readiness checks
Breaking Changes
SetRandomDigits()method removed from Queue interface - random digits are now set at construction time only (minimum 8 digits enforced)
New Features
- FIFO Queue: New
QueueFIFOtype with strict ordering per message group and exactly-once delivery per group - Standard Queue: Renamed from original implementation, best-effort FIFO with high throughput
- Factory Functions:
New()andNewWithClient()for easy queue creation
Test Infrastructure
make test- Run unit tests only (no Docker required)make test-ci- Run all tests including integration (requires Docker)make benchmark- Run benchmarks with memory, CPU profiling, and race detection
First release of dynamodb queue
This is the first release of the dynamodb queue. Checkout what it supports in godyanmodb-queue readme file.
Cheers! :)