DZone
Thanks for visiting DZone today,
Edit Profile
  • Manage Email Subscriptions
  • How to Post to DZone
  • Article Submission Guidelines
Sign Out View Profile
  • Post an Article
  • Manage My Drafts
Over 2 million developers have joined DZone.
Log In / Join
Refcards Trend Reports
Events Video Library
Refcards
Trend Reports

Events

View Events Video Library

Related

  • Exploring ML.NET Catalogs and Use Cases
  • Runtime Formula Evaluation With MVEL Library in Spring Boot
  • Implementing Effective Document Fraud Detection in C#
  • C/C++ Is Where Vulnerability Programs Go to Guess

Trending

  • The Middleware Gap in AI Agent Frameworks
  • Google Cloud AI Agents With Gemini 3: Building Multi-Agent Systems That Actually Work
  • Reproducible Development Environments, One Command Away: Introducing CodingBooth
  • Mastering Fluent Bit: Beginners' Guide for Contributing to our CNCF Project Docs
  1. DZone
  2. Coding
  3. Languages
  4. OpenSleigh: A Saga Management Library for .NET Core

OpenSleigh: A Saga Management Library for .NET Core

This article provides the latest news on OpenSleigh, a distributed saga management library written in C# with .NET Core 5.

By 
David Guida user avatar
David Guida
·
Jan. 11, 21 · News
Likes (4)
Comment
Save
Tweet
Share
10.0K Views

Join the DZone community and get the full member experience.

Join For Free

Hi All! Today I want to talk a bit about a pet project of mine I’ve been working on in the last few weeks. I call it OpenSleigh, and it’s a Saga management library for .NET Core.

For those who don’t know what the Saga Pattern is, Chris Richardson has a very good introduction on his website.

The basic idea is quite interesting: in a micro-service architecture, it often happens that we need to handle several long-running operations that span multiple services. Distributed transactions are a nasty little beast and we also need a way to keep track of the global status and manage the whole flow.

There are two main schools of thought for this: Choreography and Orchestration.

With Choreography, the logic is decentralized, scattered, and shared amongst the participants. They usually communicate using a Message Broker, like RabbitMQ or Kafka, which makes definitely easier to add and removing message publishers and consumers.

With Orchestration, instead, the logic is centralized in a single component, which is in charge of the entire workflow. Once the process is triggered, this orchestrator will take care of calling each microservice (directly or via messaging) and handling responses and faults.

OpenSleigh falls into the realm of the orchestrators. It can be added to regular Console or Web applications, will spin up a bunch of BackgroundServices, and do its magic.

The Core module of OpenSleigh can be installed from NuGet. However, Transport and Persistence packages are necessary to properly use the library.

These are the packages available at the moment:

  • OpenSleigh.Persistence.InMemory
  • OpenSleigh.Persistence.Mongo
  • OpenSleigh.Transport.RabbitMQ

Now, there are already several valuable alternatives on the market, like MassTransit and NServiceBus. So why did I started this project?

I was curious, and I’m pretty sure many of you can relate.

I wanted to see how a Saga system works from the inside. Also, I wondered if I could build one myself from scratch. I wanted to create an open-source project and create a community around it.

So, don’t hesitate! Take a look at the repository on GitHub, download the packages, play with them, and send me your feedback!

Library .NET

Opinions expressed by DZone contributors are their own.

Related

  • Exploring ML.NET Catalogs and Use Cases
  • Runtime Formula Evaluation With MVEL Library in Spring Boot
  • Implementing Effective Document Fraud Detection in C#
  • C/C++ Is Where Vulnerability Programs Go to Guess

Partner Resources

×

Comments

The likes didn't load as expected. Please refresh the page and try again.

  • RSS
  • X
  • Facebook

ABOUT US

  • About DZone
  • Support and feedback
  • Community research

ADVERTISE

  • Advertise with DZone

CONTRIBUTE ON DZONE

  • Article Submission Guidelines
  • Become a Contributor
  • Core Program
  • Visit the Writers' Zone

LEGAL

  • Terms of Service
  • Privacy Policy

CONTACT US

  • 3343 Perimeter Hill Drive
  • Suite 215
  • Nashville, TN 37211
  • [email protected]

Let's be friends:

  • RSS
  • X
  • Facebook