Explore Namastack Outbox example use cases
mainThe namastack-outbox-examples directory provides several specialized projects to demonstrate library features:
Handler Registration
- Annotation-based: Use
@OutboxHandlerfor registering handlers.
Resilience & Error Handling
- Retry Policies: Demonstrates automatic retry behavior.
- Fallback Handlers: Use
@OutboxFallbackHandlerto handle permanent failures.
Integration Patterns
- Message Brokers: Externalizing records to Apache Kafka (Java/Kotlin), RabbitMQ (Java/Kotlin), or AWS SNS (Java/Kotlin via LocalStack).
- Spring Modulith: Externalizing payment events to Kafka.
- Spring Events: Using the
multicasterexample for transaction isolation between Spring events and the outbox. - Observability: Distributed tracing with OpenTelemetry and Micrometer.
Database & Schema Management
- Database Types: JDBC (no JPA/Hibernate), JPA, MySQL, MariaDB, PostgreSQL, SQL Server, and MongoDB.
- Schema Management: Using Flyway migrations for production-ready manual schema management, or using custom H2 schemas and table prefixes via Hibernate's
PhysicalNamingStrategyor manual JDBC configuration.