Df.AuditLogging 1.0.0.16

dotnet add package Df.AuditLogging --version 1.0.0.16
NuGet\Install-Package Df.AuditLogging -Version 1.0.0.16
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="Df.AuditLogging" Version="1.0.0.16" />
For projects that support PackageReference, copy this XML node into the project file to reference the package.
paket add Df.AuditLogging --version 1.0.0.16
#r "nuget: Df.AuditLogging, 1.0.0.16"
#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.
// Install Df.AuditLogging as a Cake Addin
#addin nuget:?package=Df.AuditLogging&version=1.0.0.16

// Install Df.AuditLogging as a Cake Tool
#tool nuget:?package=Df.AuditLogging&version=1.0.0.16

A framework to handle audit logging in a more consistent way

There are two packages for this purpose:

Usage

Call pp.UseAuditLogCorrelator(); in your startup.cs or program.cs file.

And by getting the IAuditLogCorrelator from the DI container where ever you need to audit log and calling AddAudit() and AddAudits().

Source code

https://github.com/DanskeFragtmaend/Public/tree/master/src/Df.AuditLogging

Correlation

All audits in a request are put into a group with a unique ID (GUID). This ID should be saved with the audit.

X-Correlation-Id from the HTTP header is also retrieved and saved to the last audit.

IAuditUserProvider

The IAuditUserProvider interface is used to get the user ID for the current request. This is used to save the user ID with the audit. A default implementation is provided with DefaultAuditUserProvider, otherwise implement your own.

IAuditLogSource

The IAuditLogSource interface is used to save the audits to a storage. An implementation of this interface is provided by the consumer of this framework.

Saving the audits

IAuditLogSource.InsertAsync is called automatically when the request is finished. This is done by the AuditLogCorrelatorMiddleware.

Product Compatible and additional computed target framework versions.
.NET net6.0 is compatible.  net6.0-android was computed.  net6.0-ios was computed.  net6.0-maccatalyst was computed.  net6.0-macos was computed.  net6.0-tvos was computed.  net6.0-windows was computed.  net7.0 was computed.  net7.0-android was computed.  net7.0-ios was computed.  net7.0-maccatalyst was computed.  net7.0-macos was computed.  net7.0-tvos was computed.  net7.0-windows was computed.  net8.0 was computed.  net8.0-android was computed.  net8.0-browser was computed.  net8.0-ios was computed.  net8.0-maccatalyst was computed.  net8.0-macos was computed.  net8.0-tvos was computed.  net8.0-windows was computed. 
Compatible target framework(s)
Included target framework(s) (in package)
Learn more about Target Frameworks and .NET Standard.
  • net6.0

    • No dependencies.

NuGet packages (1)

Showing the top 1 NuGet packages that depend on Df.AuditLogging:

Package Downloads
Df.AuditLogging.Middleware

A framework to handle audit logging in a more consistent way

GitHub repositories

This package is not used by any popular GitHub repositories.

Version Downloads Last updated
1.0.0.16 409 2/9/2023
1.0.0.10 375 8/26/2022
1.0.0.9 366 8/26/2022
1.0.0.7 381 8/26/2022
1.0.0.6 597 8/26/2022