Event Sourcing
for Go
Built for developers who demand simplicity without sacrificing power. Production-ready event sourcing & CQRS toolkit.
store, _ := mink.NewEventStore(
postgres.NewAdapter("postgres://localhost/orders"),
)
order := NewOrder("order-123")
order.Create("customer-456")
order.AddItem("SKU-001", 2, 29.99)
store.SaveAggregate(ctx, order)
Trusted by
Everything you need to build event-driven systems
A comprehensive toolkit that covers the entire lifecycle — from event storage to projections, sagas, encryption, and beyond.
Event Store
CoreAppend-only storage with optimistic concurrency and global ordering.
Aggregates
CoreDomain-driven aggregate roots with automatic event application.
Projections
CoreInline, async, and live read models that update automatically.
Command Bus
CoreFull CQRS with middleware pipeline, validation, and idempotency.
Adapters
CorePostgreSQL for production, in-memory for testing. Swap anytime.
Encryption
EnterpriseAES-256-GCM field-level encryption with envelope encryption pattern.
GDPR Compliance
EnterpriseCrypto-shredding, data export, and right-to-erasure built in.
Sagas
EnterpriseOrchestrate long-running workflows with automatic compensation.
Outbox Pattern
EnterpriseReliable event publishing to Kafka, webhooks, and SNS.
Testing
Developer ExperienceBDD fixtures, assertion helpers, and test containers included.
Observability
Developer ExperiencePrometheus metrics and OpenTelemetry tracing out of the box.
CLI Tool
Developer ExperienceGenerate code, run migrations, diagnose issues from the terminal.
Clean, idiomatic Go
No magic. No ceremony. Just the patterns Go developers expect.
package main
import (
"context"
"go-mink.dev"
"go-mink.dev/adapters/postgres"
)
func main() {
ctx := context.Background()
// Connect to your database
store, _ := mink.NewEventStore(
postgres.NewAdapter("postgres://localhost/orders"),
)
// Create and save an aggregate
order := NewOrder("order-123")
order.Create("customer-456")
order.AddItem("SKU-001", 2, 29.99)
store.SaveAggregate(ctx, order)
}
Architecture that scales
A clean, layered architecture from commands to read models.
Blazing fast performance
Benchmarked with real workloads. Optimized for production scale.
Why choose go-mink?
See how go-mink compares to building event sourcing from scratch.
| Aspect | Traditional | go-mink |
|---|---|---|
| Event Storage | Custom implementation | Built-in, optimized |
| Projections | Manual, error-prone | Automatic, reliable |
| Database Support | Locked to one DB | Swap adapters anytime |
| Testing | Complex setup | BDD fixtures included |
| Learning Curve | Steep | Gentle, familiar API |
| Encryption | DIY per-field logic | AES-256-GCM built in |
| GDPR | Manual implementation | Crypto-shredding + export |
Ready to get started?
Add go-mink to your project and start building event-driven systems in minutes.
go get go-mink.dev