OpenSleigh: Tackling State Persistence

OpenSleigh: Tackling State Persistence

OpenSleigh: Tackling State Persistence. Here we go with another article about OpenSleigh. Today, we’re going a bit deeper into the rabbit hole to see how it is dealing with state persistency.

Here we go with another article about OpenSleigh. Today, we’re going a bit deeper into the rabbit hole to see how it is dealing with state persistency.

Hi, all! Here we go with another article about OpenSleigh. Today we’re going a bit deeper into the rabbit hole and see how it is dealing with state persistency.

The last time we introduced the library, we discussed a bit about what the Saga pattern is and what’s the general idea behind Orchestration and Choreography.

Now, Sagas are all about messages. Commands get issued and events get published. At the same time though, we have to make sure that changes to the internal state of the Saga are being persisted safely. Also, we want outgoing messages to be dispatched only when the local state is saved.

In an ideal world, we wouldn’t have to worry about this, but unfortunately, we have to deal with a bunch of nasty stuff like concurrency and horizontal scalability.

For example, let’s suppose that our application is composed of 2 services: a Web API and a background worker service. Let’s call them Orders API and Orders processor — that should help you get the picture.

The Web API is responsible for receiving client requests, packing them into nice messages, and pushing them to a service bus. The worker subscribes to those messages and uses OpenSleigh to handle Saga execution.

This is a pretty nice and standard way of handling long-running operations asynchronously. Works pretty well and, most importantly, scales pretty well.

tutorial microservices message queues opensleigh

Bootstrap 5 Complete Course with Examples

Bootstrap 5 Tutorial - Bootstrap 5 Crash Course for Beginners

Nest.JS Tutorial for Beginners

Hello Vue 3: A First Look at Vue 3 and the Composition API

Building a simple Applications with Vue 3

Deno Crash Course: Explore Deno and Create a full REST API with Deno

How to Build a Real-time Chat App with Deno and WebSockets

Convert HTML to Markdown Online

HTML entity encoder decoder Online

Data Visualization in R with ggplot2: A Beginner Tutorial

Data Visualization in R with ggplot2: A Beginner Tutorial. Learn to visualize your data using R and ggplot2 in this beginner-friendly tutorial that walks you through building a chart for data analysis.

Tutorial: Getting Started with R and RStudio

Get your R programming journey off on the right foot with this RStudio tutorial that walks through everything from installation to best practices.

Tutorial: Loading and Cleaning Data with R and the tidyverse

Learn how to load a data set and clean it using R programming and tidyverse tools in this free beginner-level data analysis tutorial.

What Are Microservices?

In this article, you will learn what are Microservices? Many people have many perspectives on Microservices, and there are many definitions. I recommend, rather than going by the definition, go by characteristics.

R Tutorial: Better Blog Post Analysis with googleAnalyticsR

Learn to compare blog posts on even footing using R programming and the googleAnalyticsR package for blog data analysis in this free tutorial.