Ranvier.Persistence.KurrentDB
0.1.1
dotnet add package Ranvier.Persistence.KurrentDB --version 0.1.1
NuGet\Install-Package Ranvier.Persistence.KurrentDB -Version 0.1.1
<PackageReference Include="Ranvier.Persistence.KurrentDB" Version="0.1.1" />
<PackageVersion Include="Ranvier.Persistence.KurrentDB" Version="0.1.1" />
<PackageReference Include="Ranvier.Persistence.KurrentDB" />
paket add Ranvier.Persistence.KurrentDB --version 0.1.1
#r "nuget: Ranvier.Persistence.KurrentDB, 0.1.1"
#:package Ranvier.Persistence.KurrentDB@0.1.1
#addin nuget:?package=Ranvier.Persistence.KurrentDB&version=0.1.1
#tool nuget:?package=Ranvier.Persistence.KurrentDB&version=0.1.1
Ranvier.Persistence.KurrentDB
Small scoped snapshots with atomic batches and optional record ETags.
Reference this project from a .NET 10 application:
open KurrentDB.Client
open Ranvier.Persistence
open Ranvier.Persistence.KurrentDB
use client = new KurrentDBClient(KurrentDBClientSettings.Create connectionString)
let store = KurrentDBStateStore(client, "customer-42") :> IStateStore
The caller owns the client. Scopes are independent, case-sensitive Unicode strings of up to 512 UTF-8 bytes.
The adapter owns each scope's ranvier-state-v1- stream.
- Every mutation appends the complete scope, limited to 1 MiB of encoded JSON.
- Save batches commit atomically. Duplicate keys, malformed tags and invalid Unicode are rejected.
- A loaded ETag supports conditional saves. A changed or absent record raises
KurrentDBStateConflictException; reload after successful saves for new tokens. Unrelated records retain their ETags. - A missing ETag permits an unconditional insert or replacement.
PersistSessioncurrently writes this way. - A mutation attempts up to 32 appends on stream conflicts, waiting 1–50 ms between attempts before reading a fresh snapshot. Other failures propagate.
- Delete and clear remove current records within the scope. Historical snapshot events remain.
- Reserve the stream for this adapter. External writes, physical deletion and age-based expiry can invalidate state.
Use this adapter for small snapshots. Writes copy all scoped records, and history grows with every mutation. Manage retention explicitly; retain at least the latest event. A connection failure can leave the commit acknowledgement uncertain; reload before retrying a conditional write.
The KurrentDB guide includes setup and a persisted signal round-trip. The adapter adds KurrentDB.Client only to this package; core persistence stays independent.
Run the integration suite against a disposable server:
# Set RANVIER_KURRENTDB_CONNECTION first.
dotnet test tests/Ranvier.Persistence.KurrentDB.Tests -c Release
A missing connection or unavailable server fails the tests. CI runs both package variants against its own pinned container; the ordinary build CLI excludes this integration project.
| 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
- FSharp.Core (>= 10.1.404)
- KurrentDB.Client (>= 1.4.1)
- Ranvier.Persistence (>= 0.1.1)
NuGet packages
This package is not used by any NuGet packages.
GitHub repositories
This package is not used by any popular GitHub repositories.
| Version | Downloads | Last Updated |
|---|---|---|
| 0.1.1 | 50 | 11/14/2026 |
| 0.1.1-preview.1 | 68 | 10/28/2026 |
| 0.1.0-preview.2 | 55 | 10/27/2026 |
| 0.1.0-preview.1 | 59 | 10/26/2026 |
Pre-1.0 release. The API may change before 1.0.