Purview.EventSourcing.SqlServer
2.0.0-prerelease.31
dotnet add package Purview.EventSourcing.SqlServer --version 2.0.0-prerelease.31
NuGet\Install-Package Purview.EventSourcing.SqlServer -Version 2.0.0-prerelease.31
<PackageReference Include="Purview.EventSourcing.SqlServer" Version="2.0.0-prerelease.31" />
<PackageVersion Include="Purview.EventSourcing.SqlServer" Version="2.0.0-prerelease.31" />
<PackageReference Include="Purview.EventSourcing.SqlServer" />
paket add Purview.EventSourcing.SqlServer --version 2.0.0-prerelease.31
#r "nuget: Purview.EventSourcing.SqlServer, 2.0.0-prerelease.31"
#:package Purview.EventSourcing.SqlServer@2.0.0-prerelease.31
#addin nuget:?package=Purview.EventSourcing.SqlServer&version=2.0.0-prerelease.31&prerelease
#tool nuget:?package=Purview.EventSourcing.SqlServer&version=2.0.0-prerelease.31&prerelease
Purview.EventSourcing.SqlServer
Purview.EventSourcing.SqlServer provides both SQL Server/Azure SQL event-stream persistence and SQL-backed queryable snapshot persistence for Purview EventSourcing.
Install
dotnet add package Purview.EventSourcing.SqlServer
Register the providers
builder.Services.AddSqlServerEventStore();
builder.Services.AddSqlServerSnapshotQueryableEventStore();
{
"ConnectionStrings": {
"eventstore-sqlserver": "Server=.;Database=MyApp;Trusted_Connection=True;"
}
}
What it provides
- Event-stream persistence for aggregates loaded through
IEventStore - Query/list/count snapshot-backed reads through
IQueryableEventStore - SQL-specific transaction factory (
ISqlServerEventStoreTransactionFactory) for enlisting additional SQL/EF work in the same commit (all enlisted stores must share the same SQL transaction boundary) - SQL Server and Azure SQL configuration binding for both event and snapshot stores
- Entity Framework-backed schema creation and CRUD paths
- JSON-column-backed event and snapshot payload storage
- Shared-table safety: when aggregate types share a table, event-stream reads and deletes are scoped by both aggregate id and aggregate type
- Tolerant replay for long-lived streams: integration-tested handling for unknown event types and schema-evolved/unappliable historical events
Payload shape
The snapshot payload is the fully serialized aggregate graph stored in a single JSON column. EF queries run against that JSON payload, so aggregate properties remain transparent to callers.
Supported members are writable primitives, [Scalar] value objects, complex objects composed of supported members, and EventStoreList<T> / EventStoreSet<T> collections of supported primitive or complex members.
Important query distinction:
- A
[Scalar]value object with a primitive inner value is generally query-friendly. - A
[Scalar]value object with a complex inner value is persisted correctly, but deep predicates through.Valueare not guaranteed to translate in SQL snapshot queries. - If deep SQL predicates are required for a complex concept, expose the underlying complex type directly on the aggregate/query snapshot model (for example, a
ParserReportSummarymirror property) and verify the exact nested predicate with integration tests.
Unsupported shapes fail during model creation, including arrays and collection types other than EventStoreList<T> / EventStoreSet<T> (for example List<T>, IReadOnlyList<T>, IEnumerable<T>, HashSet<T>, ImmutableArray<T>), except where a provider-specific JSON conversion path is explicitly supported and tested. Read-only and [JsonIgnore] members are excluded from the JSON payload.
Documentation
- Repository README
- SQL Server guide
- Includes behavior notes/caveats (
IsDeletedAsyncmissing behavior, tolerant replay, principal requirements) - Includes snapshot payload/query-translation guidance for scalar value objects vs directly mapped complex mirrors
- Includes behavior notes/caveats (
| Product | Versions 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. |
-
net10.0
- LinqKit (>= 1.3.11)
- Microsoft.Data.SqlClient (>= 7.0.3)
- Microsoft.EntityFrameworkCore (>= 10.0.12)
- Microsoft.EntityFrameworkCore.Relational (>= 10.0.12)
- Microsoft.EntityFrameworkCore.SqlServer (>= 10.0.12)
- Microsoft.Extensions.Caching.Abstractions (>= 10.0.12)
- Microsoft.Extensions.Configuration.Abstractions (>= 10.0.12)
- Microsoft.Extensions.Configuration.Binder (>= 10.0.12)
- Microsoft.Extensions.DependencyInjection (>= 10.0.12)
- Microsoft.Extensions.DependencyInjection.Abstractions (>= 10.0.12)
- Microsoft.Extensions.Hosting.Abstractions (>= 10.0.12)
- Microsoft.Extensions.Logging (>= 10.0.12)
- Microsoft.Extensions.Logging.Abstractions (>= 10.0.12)
- Microsoft.Extensions.Options (>= 10.0.12)
- Microsoft.Extensions.Telemetry.Abstractions (>= 10.10.0)
- Purview.EventSourcing (>= 2.0.0-prerelease.31)
NuGet packages (1)
Showing the top 1 NuGet packages that depend on Purview.EventSourcing.SqlServer:
| Package | Downloads |
|---|---|
|
Purview.EventSourcing.Admin.SqlServer
SQL Server query adapters for Purview EventSourcing Admin Portal. |
GitHub repositories
This package is not used by any popular GitHub repositories.
| Version | Downloads | Last Updated |
|---|---|---|
| 2.0.0-prerelease.31 | 42 | 9/12/2026 |
| 2.0.0-prerelease.30 | 55 | 9/8/2026 |
| 2.0.0-prerelease.29 | 79 | 8/3/2026 |
| 2.0.0-prerelease.28 | 76 | 7/20/2026 |
| 2.0.0-prerelease.27 | 57 | 7/20/2026 |
| 2.0.0-prerelease.26 | 64 | 7/20/2026 |
| 2.0.0-prerelease.25 | 57 | 7/20/2026 |
| 2.0.0-prerelease.23 | 65 | 7/20/2026 |
| 2.0.0-prerelease.22 | 63 | 7/19/2026 |
| 2.0.0-prerelease.21 | 86 | 6/26/2026 |
| 2.0.0-prerelease.20 | 78 | 6/26/2026 |
| 2.0.0-prerelease.19 | 82 | 6/26/2026 |
| 2.0.0-prerelease.18 | 83 | 6/25/2026 |
| 2.0.0-prerelease.16 | 85 | 6/23/2026 |
| 2.0.0-prerelease.15 | 81 | 6/22/2026 |
| 2.0.0-prerelease.14 | 85 | 6/22/2026 |
| 2.0.0-prerelease.13 | 77 | 6/21/2026 |
| 2.0.0-prerelease.4 | 113 | 6/17/2026 |
| 2.0.0-prerelease.3 | 74 | 6/17/2026 |
| 2.0.0-prerelease.2 | 79 | 6/17/2026 |