CanDoItAll.Ledger.Persistence.EFCore
0.1.18
dotnet add package CanDoItAll.Ledger.Persistence.EFCore --version 0.1.18
NuGet\Install-Package CanDoItAll.Ledger.Persistence.EFCore -Version 0.1.18
<PackageReference Include="CanDoItAll.Ledger.Persistence.EFCore" Version="0.1.18" />
<PackageVersion Include="CanDoItAll.Ledger.Persistence.EFCore" Version="0.1.18" />
<PackageReference Include="CanDoItAll.Ledger.Persistence.EFCore" />
paket add CanDoItAll.Ledger.Persistence.EFCore --version 0.1.18
#r "nuget: CanDoItAll.Ledger.Persistence.EFCore, 0.1.18"
#:package CanDoItAll.Ledger.Persistence.EFCore@0.1.18
#addin nuget:?package=CanDoItAll.Ledger.Persistence.EFCore&version=0.1.18
#tool nuget:?package=CanDoItAll.Ledger.Persistence.EFCore&version=0.1.18
CanDoItAll.Ledger.Persistence.EFCore
Provider-neutral Entity Framework Core stores, history readers, projections, snapshots, and schema contracts for CanDoItAll Ledger.
Use this package when implementing an EF Core-backed Ledger host or a custom
relational provider. For a supported durable deployment, use
CanDoItAll.Ledger.Persistence.PostgreSql, which supplies the provider and
migrations.
Requirements
- .NET 10
- An EF Core provider when using
AddLedgerEfCoreStores()
Install
dotnet add package CanDoItAll.Ledger.Persistence.EFCore
Disposable Test Store
using CanDoItAll.Ledger.Persistence.EFCore;
builder.Services.AddLedgerInMemoryPersistence("ledger-tests");
AddLedgerInMemoryPersistence uses Microsoft.EntityFrameworkCore.InMemory.
It is not SQLite, relational, durable, or suitable for authoritative expense
records. Use it for isolated tests and disposable development only.
Custom Provider Composition
using CanDoItAll.Ledger.Persistence.EFCore;
using Microsoft.EntityFrameworkCore;
builder.Services.AddDbContextFactory<LedgerDbContext>(options =>
{
// Configure the relational provider selected and owned by this host.
});
builder.Services.AddLedgerEfCoreStores();
The host must supply IDbContextFactory<LedgerDbContext>.
AddLedgerEfCoreStores() registers:
ILedgerStorethroughEfLedgerStore;- history and transaction readers;
- projection verification and rebuilding;
- snapshots;
- the provider-neutral schema migrator.
Concrete relational migrations belong to the provider package. The PostgreSQL package replaces the base migrator with its provider-aware implementation.
Persistence Notes
- Treat the Ledger database as authoritative durable data and use database-native backups.
- Run projection verification after migration or repair work; projections are derived from confirmed transaction history.
- Coordinate startup migration policy in the host. Registration alone does not migrate a database.
- Stable
Economy_*relational names are persisted compatibility identifiers; renaming them requires an explicit data migration and compatibility review. - Do not expose EF entities as public API contracts.
See the PostgreSQL provider, persistence operations, and full source.
This package is part of the CanDoItAll ecosystem and uses the repository's MIT License.
| 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
- CanDoItAll.Ledger.Core (>= 0.1.18)
- Microsoft.EntityFrameworkCore (>= 10.0.10)
- Microsoft.EntityFrameworkCore.InMemory (>= 10.0.10)
- Microsoft.EntityFrameworkCore.Relational (>= 10.0.10)
NuGet packages (1)
Showing the top 1 NuGet packages that depend on CanDoItAll.Ledger.Persistence.EFCore:
| Package | Downloads |
|---|---|
|
CanDoItAll.Ledger.Persistence.PostgreSql
PostgreSQL provider, migrations, schema adoption, and resilient dependency-injection setup for CanDoItAll Ledger. |
GitHub repositories
This package is not used by any popular GitHub repositories.