Skip to content
@stacksaga

StackSaga

StackSaga Saga Orchestration - Java spring boot
StackSaga — The Next Evolution of Saga Orchestration

License: SSAL-1.0 Spring Boot Java Project Reactor Docs Discussions Docker Hub Stack Overflow


The Next Evolution of Saga Orchestration

StackSaga is the domain-centric, natively reactive saga orchestration ecosystem for Spring Boot.

Build resilient, high-throughput distributed microservices with zero dedicated orchestrator servers, zero Transactional Outbox, and automated reverse compensation — in a developer-friendly, compile-time type-safe environment.

"One framework. From Modular Monolith to full microservices — with zero saga rewrites."

→ Read the full introduction


Why StackSaga?

StackSaga Temporal / Camunda Kafka Choreography
Dedicated Servers ✅ Zero — embedded in your service ❌ Heavy external cluster ⚠️ Broker clusters only
Execution Model ✅ Natively Reactive (Project Reactor) ❌ Thread-pool long-polling ⚠️ Consumer thread pools
Mixed STP + HITL ✅ Native in one pipeline ❌ Requires external orchestration ❌ Fragile ad-hoc state machines
Type Safety ✅ 100% compile-time verified ⚠️ Partially typed ❌ Untyped JSON + string topics
Transactional Outbox ✅ Eliminated — atomic Event Store ❌ Required for every trigger ❌ Required before every publish
Monolith → Microservices ✅ Zero-rewrite extraction ❌ Microservices-only ❌ Forces broker between modules
Downstream Coupling ✅ Zero — pure REST / gRPC APIs ❌ SDK installation required ❌ Topic binding required

→ Full architectural deep-dive


Core Capabilities

⚡ Natively Reactive & Non-Blocking

Built on Project Reactor from the ground up. The entire Saga Execution Coordinator (SEC) is non-blocking — thousands of concurrent sagas run on minimal CPU threads with zero thread exhaustion. → Reactive Executor Docs

🔀 Unified Saga Model (USM) — STP + HITL in One Pipeline

The first framework to execute mixed-style sagas in the same pipeline: Continuous STP (sub-millisecond automated processing) and Pausable HITL (days-long human approval wait-states that release 100% of worker threads). → USM Whitepaper & Specification

🛡️ Spaghetti-Less, Compile-Time Type-Safe Architecture

Strongly-typed CommandExecutor<T> and QueryExecutor<T> generics with compiler-verified step transitions — no broken string references, full IDE autocomplete, refactor-safe pipelines. → Executor Architecture

🏗️ Domain-Centric — Monolith to Microservices, Zero Rewrites

Run as an in-process Modular Monolith at <1ms speeds today. When you extract a module into a standalone microservice, your saga pipelines, compensations, and event log stay 100% intact. Requires Java 21+ and Spring Boot 4.x. → Architecture Overview

🔄 1-to-Many Multi-Stage Compensations

Real enterprise rollbacks need more than a single undo. Chain Pre-RevertExecutor → doRevert() → Post-RevertExecutor for fraud holds, audit logs, and customer notifications — without polluting primary business logic. → Compensation & Revert Patterns

🗄️ Zero-Infrastructure Event Sourcing

Your existing PostgreSQL, MySQL, Oracle, or Cassandra database becomes the immutable event store. Event Store writes commit atomically within the same ACID transaction as your domain logic — the Transactional Outbox pattern is completely eliminated. → Event Store & Database Support

🔁 Lock-Free Distributed Retries

Murmur3 token-ring partitioning assigns conflict-free retry ownership across cluster nodes — no locks, no single point of failure, automatic self-healing rebalancing on scale-out. → Ring Coordinator Docs


The Ecosystem

🔧 Unified Orchestrator Engine (SEC)

stacksaga-spring-boot-starter

Domain-embedded execution coordinator. Drives Continuous STP, Pausable HITL, Two-Stage messaging, and deterministic reverse compensation — all in one framework.

→ SEC Documentation

🗃️ Zero-Infrastructure Event Store

stacksaga-database-support

Turns your existing database (MySQL, PostgreSQL, Oracle, Cassandra, ScyllaDB) into an immutable saga event store. No extra clusters. No background pollers.

→ Database Support Docs

🔁 Ring Coordinator

stacksaga-ring-coordinator

Cluster coordination via Murmur3 token-ring partitioning. Conflict-free, lock-free retry ownership assignment across nodes. Zero SPOF.

→ Ring Coordinator Docs

📊 Trace Window

stacksaga-trace-window

Real-time visualization of saga executions, step states, and failure diagnostics. Data stays inside your VPC. Manual replay for incident recovery.

→ Trace Window Docs

Start with SEC + Event Store. Add Ring Coordinator for distributed retries. Add Trace Window for full observability.


Get Started in Minutes

Step 1 — Generate your project config with StackSaga Initializer Select your Spring Boot version, build tool, orchestrator type, and database — get the exact BOM and dependencies to paste into your project.

Step 2 — Follow the Quick Start guide Add the generated dependencies to your Spring Boot service and configure your data source.

Step 3 — Define your first saga Register executors, define step transitions, and start orchestrating.


Resources

Resource Link
📖 Documentation docs.stacksaga.org
🚀 Project Initializer init.stacksaga.org
📐 USM Whitepaper & Specification docs.stacksaga.org › unified-saga-patterns
🏗️ Architecture Overview docs.stacksaga.org › architecture
🔭 Trace Window Cloud trace.stacksaga.org
💬 Discussions & FAQs GitHub Discussions
🌐 Website stacksaga.org
🐳 Docker Hub hub.docker.com/u/stacksaga
💡 Stack Overflow stackoverflow.com/search?q=stacksaga
📜 License (SSAL 1.0) stacksaga.org › license › ssal-1.0

Built with ❤️ by Zoftstack

StackSaga and the StackSaga logo are trademarks of Zoftstack.

Popular repositories Loading

  1. stacksaga-docs stacksaga-docs Public

    Python

  2. stacksaga-community stacksaga-community Public

    Issue tracker and community space for StackSaga, a distributed saga orchestration framework for Spring Boot. (Covers all modules)

  3. .github .github Public

  4. stacksaga-ide-plugin stacksaga-ide-plugin Public

    Kotlin

Repositories

Showing 4 of 4 repositories

Top languages

Loading…

Most used topics

Loading…