![]() |
VOOZH | about |
dotnet add package Excalibur.EventSourcing.CosmosDb --version 3.0.0-alpha.208
NuGet\Install-Package Excalibur.EventSourcing.CosmosDb -Version 3.0.0-alpha.208
<PackageReference Include="Excalibur.EventSourcing.CosmosDb" Version="3.0.0-alpha.208" />
<PackageVersion Include="Excalibur.EventSourcing.CosmosDb" Version="3.0.0-alpha.208" />Directory.Packages.props
<PackageReference Include="Excalibur.EventSourcing.CosmosDb" />Project file
paket add Excalibur.EventSourcing.CosmosDb --version 3.0.0-alpha.208
#r "nuget: Excalibur.EventSourcing.CosmosDb, 3.0.0-alpha.208"
#:package Excalibur.EventSourcing.CosmosDb@3.0.0-alpha.208
#addin nuget:?package=Excalibur.EventSourcing.CosmosDb&version=3.0.0-alpha.208&prereleaseInstall as a Cake Addin
#tool nuget:?package=Excalibur.EventSourcing.CosmosDb&version=3.0.0-alpha.208&prereleaseInstall as a Cake Tool
Azure Cosmos DB event store implementation for Excalibur event sourcing.
{aggregateType}:{aggregateId} as partition keydotnet add package Excalibur.EventSourcing.CosmosDb
services.AddCosmosDbEventStore(options =>
{
options.EventsContainerName = "events";
options.PartitionKeyPath = "/streamId";
options.UseTransactionalBatch = true;
options.MaxBatchSize = 100;
options.ChangeFeedPollIntervalMs = 1000;
options.CreateContainerIfNotExists = true;
options.ContainerThroughput = 400;
});
Or via configuration:
services.AddCosmosDbEventStore(configuration.GetSection("CosmosDbEventStore"));
The package registers both IEventStore and ICloudNativeEventStore:
public class MyService
{
private readonly IEventStore _eventStore;
public MyService(IEventStore eventStore)
{
_eventStore = eventStore;
}
public async Task AppendEventsAsync(
string aggregateId,
IEnumerable<IDomainEvent> events,
long expectedVersion,
CancellationToken ct)
{
var result = await _eventStore.AppendEventsAsync(
aggregateId,
"MyAggregate",
events.ToList(),
expectedVersion,
ct);
if (!result.Success)
{
// Handle concurrency conflict or failure
}
}
}
For partition-aware operations, use ICloudNativeEventStore:
public class CloudNativeService
{
private readonly ICloudNativeEventStore _eventStore;
public CloudNativeService(ICloudNativeEventStore eventStore)
{
_eventStore = eventStore;
}
public async Task LoadWithPartitionAsync(CancellationToken ct)
{
var partition = new PartitionKey("MyAggregate", "aggregate-123");
var result = await _eventStore.LoadEventsAsync(partition, 0, ct);
// Process events...
}
}
Subscribe to event changes for projections or other event handlers:
await using var subscription = await _eventStore.SubscribeToChangesAsync(ct);
await subscription.StartAsync(ct);
await foreach (var change in subscription.ReadChangesAsync(ct))
{
// Process event change
Console.WriteLine($"Event: {change.Document?.EventType}");
}
Excalibur.Data.CosmosDb for connection managementSee LICENSE files in repository root.
| Product | Versions Compatible and additional computed target framework versions. |
|---|---|
| .NET | net10.0 net10.0 is compatible. net10.0-android net10.0-android was computed. net10.0-browser net10.0-browser was computed. net10.0-ios net10.0-ios was computed. net10.0-maccatalyst net10.0-maccatalyst was computed. net10.0-macos net10.0-macos was computed. net10.0-tvos net10.0-tvos was computed. net10.0-windows net10.0-windows was computed. |
This package is not used by any NuGet packages.
This package is not used by any popular GitHub repositories.
| Version | Downloads | Last Updated |
|---|---|---|
| 3.0.0-alpha.208 | 45 | 6/11/2026 |
| 3.0.0-alpha.207 | 43 | 6/11/2026 |
| 3.0.0-alpha.205 | 49 | 6/10/2026 |
| 3.0.0-alpha.204 | 67 | 6/8/2026 |
| 3.0.0-alpha.203 | 56 | 6/8/2026 |
| 3.0.0-alpha.202 | 44 | 6/8/2026 |
| 3.0.0-alpha.201 | 47 | 6/8/2026 |
| 3.0.0-alpha.199 | 48 | 6/8/2026 |
| 3.0.0-alpha.198 | 53 | 5/28/2026 |
| 3.0.0-alpha.197 | 65 | 5/28/2026 |
| 3.0.0-alpha.194 | 54 | 5/20/2026 |
| 3.0.0-alpha.193 | 53 | 5/13/2026 |
| 3.0.0-alpha.192 | 48 | 5/13/2026 |
| 3.0.0-alpha.191 | 50 | 5/13/2026 |
| 3.0.0-alpha.189 | 49 | 5/12/2026 |
| 3.0.0-alpha.187 | 59 | 5/8/2026 |
| 3.0.0-alpha.185 | 51 | 5/7/2026 |
| 3.0.0-alpha.183 | 48 | 5/7/2026 |
| 3.0.0-alpha.182 | 48 | 5/6/2026 |
| 3.0.0-alpha.181 | 51 | 5/6/2026 |