Excalibur.EventSourcing.SqlServer 10.0.0-alpha.10

This is a prerelease version of Excalibur.EventSourcing.SqlServer.
dotnet add package Excalibur.EventSourcing.SqlServer --version 10.0.0-alpha.10
                    
NuGet\Install-Package Excalibur.EventSourcing.SqlServer -Version 10.0.0-alpha.10
                    
This command is intended to be used within the Package Manager Console in Visual Studio, as it uses the NuGet module's version of Install-Package.
<PackageReference Include="Excalibur.EventSourcing.SqlServer" Version="10.0.0-alpha.10" />
                    
For projects that support PackageReference, copy this XML node into the project file to reference the package.
<PackageVersion Include="Excalibur.EventSourcing.SqlServer" Version="10.0.0-alpha.10" />
                    
Directory.Packages.props
<PackageReference Include="Excalibur.EventSourcing.SqlServer" />
                    
Project file
For projects that support Central Package Management (CPM), copy this XML node into the solution Directory.Packages.props file to version the package.
paket add Excalibur.EventSourcing.SqlServer --version 10.0.0-alpha.10
                    
#r "nuget: Excalibur.EventSourcing.SqlServer, 10.0.0-alpha.10"
                    
#r directive can be used in F# Interactive and Polyglot Notebooks. Copy this into the interactive tool or source code of the script to reference the package.
#:package Excalibur.EventSourcing.SqlServer@10.0.0-alpha.10
                    
#:package directive can be used in C# file-based apps starting in .NET 10 preview 4. Copy this into a .cs file before any lines of code to reference the package.
#addin nuget:?package=Excalibur.EventSourcing.SqlServer&version=10.0.0-alpha.10&prerelease
                    
Install as a Cake Addin
#tool nuget:?package=Excalibur.EventSourcing.SqlServer&version=10.0.0-alpha.10&prerelease
                    
Install as a Cake Tool

Excalibur.EventSourcing.SqlServer

SQL Server implementation of event sourcing infrastructure for the Excalibur framework.

Part Of

This package is included in the following metapackages:

Metapackage Tier What It Adds
Excalibur.Dispatch.SqlServer Starter + Dispatch core + Outbox + Hosting
Excalibur.SqlServer Complete + Inbox + Saga + Leader Election + Audit + Compliance + Data

Tip: Install Excalibur.SqlServer for a production-ready SQL Server stack with a single package reference.

Installation

dotnet add package Excalibur.EventSourcing.SqlServer

Features

  • SqlServerEventStore - Dapper-based event store implementation
  • SqlServerSnapshotStore - SQL Server snapshot persistence
  • Optimized for high-throughput event streaming
  • Connection factory pattern for multi-database scenarios
  • AOT-compatible with full Native AOT support
  • NO Entity Framework Core dependency

Usage

// Recommended: Builder-integrated registration
services.AddExcalibur(x => x.AddEventSourcing(es =>
{
    es.UseSqlServer(options =>
    {
        options.ConnectionString = connectionString;
        options.EventStoreSchema = "events";
    });
    es.AddRepository<OrderAggregate, Guid>(id => new OrderAggregate(id));
}));

// Alternative: Direct registration
services.AddSqlServerEventSourcing(options =>
{
    options.ConnectionString = connectionString;
});

Database Schema

The store does not create its tables at runtime. Provision them before the first append, by running the scripts shipped inside this package under scripts/:

Script Creates Required
scripts/001_CreateEventStoreSchema.sql dbo.EventStoreEvents Yes — this is the event store itself
scripts/002_CreateSnapshotSchema.sql dbo.EventStoreSnapshots Only if you enable snapshots
scripts/003_MigrateToMultiTenant.sql Upgrade only, see below
scripts/004_MakeEventTenantTotal.sql Upgrade only, see below

Both create scripts are guarded, so re-running them against an existing database is a no-op.

Upgrading an existing database

Run these in order; each is guarded and safe to run against a database that is already converged.

003_MigrateToMultiTenant.sql grows a store created before tenancy existed into the current schema. Without it, an existing deployment fails on the first append with Invalid column name 'TenantId'.

004_MakeEventTenantTotal.sql then backfills EventStoreEvents.TenantId from NULL to the reserved __untenanted__ sentinel and makes the column NOT NULL, so an untenanted event is a value rather than a missing one, and an upgraded database ends up in the same shape as a fresh one. It is not needed for a fresh install — 001 already creates the column that way. Its pre-flight step reports any stream version that already holds both a NULL and a literal sentinel row; resolve those before continuing, because only you can decide which append survives.

Both upgrade scripts rebuild a unique constraint on the system of record, so run them in a maintenance window with the store stopped, against a backup you have restored at least once.

  • Excalibur.EventSourcing - Core event sourcing abstractions
  • Excalibur.Data.Abstractions - Data access patterns

License

This project is multi-licensed under:

See LICENSE for details.

Product Compatible and additional computed target framework versions.
.NET net10.0 is compatible.  net10.0-android was computed.  net10.0-browser was computed.  net10.0-ios was computed.  net10.0-maccatalyst was computed.  net10.0-macos was computed.  net10.0-tvos was computed.  net10.0-windows was computed. 
Compatible target framework(s)
Included target framework(s) (in package)
Learn more about Target Frameworks and .NET Standard.

NuGet packages (1)

Showing the top 1 NuGet packages that depend on Excalibur.EventSourcing.SqlServer:

Package Downloads
Excalibur.Dispatch.SqlServer

Experience metapackage bundling Excalibur.Dispatch with SQL Server event sourcing and a SQL Server outbox store. Provides a single AddDispatchWithSqlServer() call for the common SQL Server scenario. The outbox stages messages durably; background delivery is opt-in. PRE-RELEASE: the public API is not frozen and may change between pre-release builds. Not recommended for production use. Known issues: https://docs.excalibur-dispatch.dev/docs/known-issues

GitHub repositories

This package is not used by any popular GitHub repositories.

Version Downloads Last Updated
10.0.0-alpha.10 66 9/6/2026
10.0.0-alpha.9 74 8/31/2026
10.0.0-alpha.8 85 8/14/2026
10.0.0-alpha.7 76 8/13/2026
10.0.0-alpha.6 81 8/11/2026
10.0.0-alpha.5 74 8/10/2026
10.0.0-alpha.4 70 8/10/2026
3.0.0-alpha.216 90 6/30/2026
3.0.0-alpha.215 90 6/23/2026
3.0.0-alpha.214 85 6/23/2026
3.0.0-alpha.208 83 6/11/2026
3.0.0-alpha.207 90 6/11/2026
3.0.0-alpha.205 90 6/10/2026
3.0.0-alpha.204 89 6/8/2026
3.0.0-alpha.203 87 6/8/2026
3.0.0-alpha.202 78 6/8/2026
3.0.0-alpha.201 76 6/8/2026
3.0.0-alpha.199 79 6/8/2026
3.0.0-alpha.198 83 5/28/2026
3.0.0-alpha.197 87 5/28/2026
Loading failed