KitStack.Audit.Sinks.EntityFrameworkCore 0.1.9

dotnet add package KitStack.Audit.Sinks.EntityFrameworkCore --version 0.1.9
                    
NuGet\Install-Package KitStack.Audit.Sinks.EntityFrameworkCore -Version 0.1.9
                    
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="KitStack.Audit.Sinks.EntityFrameworkCore" Version="0.1.9" />
                    
For projects that support PackageReference, copy this XML node into the project file to reference the package.
<PackageVersion Include="KitStack.Audit.Sinks.EntityFrameworkCore" Version="0.1.9" />
                    
Directory.Packages.props
<PackageReference Include="KitStack.Audit.Sinks.EntityFrameworkCore" />
                    
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 KitStack.Audit.Sinks.EntityFrameworkCore --version 0.1.9
                    
#r "nuget: KitStack.Audit.Sinks.EntityFrameworkCore, 0.1.9"
                    
#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 KitStack.Audit.Sinks.EntityFrameworkCore@0.1.9
                    
#: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=KitStack.Audit.Sinks.EntityFrameworkCore&version=0.1.9
                    
Install as a Cake Addin
#tool nuget:?package=KitStack.Audit.Sinks.EntityFrameworkCore&version=0.1.9
                    
Install as a Cake Tool

KitStack.Audit.Sinks.EntityFrameworkCore

A relational sink for KitStack.Audit. It persists captured TrailDtos as flat AuditTrail rows via its own AuditDbContext, on any EF Core relational provider.

This package is provider-agnostic — it references EF Core but not a specific driver. You supply UseSqlServer / UseNpgsql / UseSqlite etc. at registration.

Wiring

services.AddKitStackAuditEntityFrameworkCoreSink(o =>
    o.UseSqlServer(configuration.GetConnectionString("Audit")));

This registers AuditDbContext and IAuditSink -> EfCoreAuditSink. Combine with KitStack.Audit.EntityFrameworkCore (the capture source) so the interceptor has a sink to write to.

Schema

  • Table AuditTrails, keyed on Id.
  • Operation, Entity, Module are bounded strings.
  • PreviousValues, NewValues, ModifiedProperties, PrimaryKey hold JSON and use the provider's large-text type.
  • Indexes on DateTime, Entity, and UserId.

Create the schema with an EF Core migration against AuditDbContext (or EnsureCreated() in development). The audit store is intentionally separate from your application database.

Behavior

  • Inserts the batch, swallows and logs any failure (auditing never breaks the business transaction).
  • AuditDbContext does not implement IAuditableDbContext, so the audit store is never itself audited.

License

Apache-2.0

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 KitStack.Audit.Sinks.EntityFrameworkCore:

Package Downloads
KitStack.Audit.AspNetCore

ASP.NET Core wiring for KitStack.Audit: one-call setup, sink selection, narration, and health checks.

GitHub repositories

This package is not used by any popular GitHub repositories.

Version Downloads Last Updated
0.1.9 142 6/10/2026
0.1.8 122 6/9/2026
0.1.7 129 6/9/2026
0.1.6 124 6/9/2026
0.1.5 135 6/9/2026