Header menu logo FCQRS

FCQRS Documentation

FCQRS is a F#-based implementation of the Command Query Responsibility Segregation (CQRS) pattern. By leveraging Akka.NET for actor-based concurrency, FCQRS allows you to encapsulate aggregates within actors that process commands, generate events, and manage long-running business processes via sagas. The framework is designed to protect your core domain logic while providing the flexibility to evolve your read models independently.

Introduction

FCQRS is designed to simplify the implementation of CQRS in F#. It integrates with Akka.NET, allowing developers to leverage the actor model for representing aggregates. This separation between command handling and query processing protects your core domain from changes that arise due to evolving reporting requirements.

Why CQRS and Event Sourcing?

The primary motivation behind adopting CQRS is the differing requirements of the read and write sides of an application:

Key Features

Abstraction of Akka.NET

FCQRS abstracts away the complexities of Akka.NET, so you can focus on defining your aggregates as actors without needing to manage the low-level details of actor management.

Command and Event Handling

Saga Implementation

FCQRS supports sagas (process managers) that orchestrate long-running business processes. This separation allows your domain aggregates to remain free of side effects, improving testability and maintainability.

Getting Started

Installation and Setup

  1. Prerequisites: .NET 9 SDK.
  2. Packages: Add the following nuget packages to your project using your preferred package manager:
    • FCQRS
    • Hocon.Extensions.Configuration (optional, for HOCON configuration)
    • Microsoft.Extensions.Logging.Console (optional, for logging)

Type something to start searching.