Anarchy.Toolkit.Core.Observability
1.0.6
See the version list below for details.
dotnet add package Anarchy.Toolkit.Core.Observability --version 1.0.6
NuGet\Install-Package Anarchy.Toolkit.Core.Observability -Version 1.0.6
<PackageReference Include="Anarchy.Toolkit.Core.Observability" Version="1.0.6" />
<PackageVersion Include="Anarchy.Toolkit.Core.Observability" Version="1.0.6" />
<PackageReference Include="Anarchy.Toolkit.Core.Observability" />
paket add Anarchy.Toolkit.Core.Observability --version 1.0.6
#r "nuget: Anarchy.Toolkit.Core.Observability, 1.0.6"
#:package Anarchy.Toolkit.Core.Observability@1.0.6
#addin nuget:?package=Anarchy.Toolkit.Core.Observability&version=1.0.6
#tool nuget:?package=Anarchy.Toolkit.Core.Observability&version=1.0.6
Anarchy.Toolkit.Core.Observability
Observability primitives centered on the Observer facade for logging, metrics and context.
dotnet add package Anarchy.Toolkit.Core.Observability
- Use
Observerwith itsLogger,MeasurerBaseandLogContextto instrument application code. - Attach
Tagsand call-site information withCallSiteEntity,CalledFrom()andParentCaller(). DevelopmentLoggerandLoggerMeasurerprovide development-friendly implementations.
When to use it
Use Observer in services and adapters that need consistent structured logs and metrics without choosing an organization-specific telemetry backend. It wraps Serilog logging and a measurement abstraction; the host still needs to configure their implementations and destinations.
How to use it
Inject an Observer into the component being instrumented. Prefer call-site-aware wrappers and structured properties:
using Anarchy.Toolkit.Core.Observability.Extension;
using Anarchy.Toolkit.Core.Observability.Service.Observability;
var caller = this.CalledFrom();
observer.LogInformation(caller, "Processing user {UserId}", userId);
observer.ExecutionIncrementCount(caller, 1, Tags.Success);
Use observer.MonitoredActionAsync for an async action that should report duration and outcome. Keep high-cardinality values such as IDs in logs rather than metric tags. Configuration supplies a host-level ObserverFactory; Testing supplies an in-memory observer for assertions.
See the observability guide and toolkit overview.
Releases
1.0.6
- docs: expand XML docblocks across all projects for the DocFX API reference
1.0.5
- refactor(src): clean up code style across library packages
1.0.3
- build: migrate local automation to build tooling
1.0.2
- docs: expand package guides and release histories
1.0.1
- Added a package-specific NuGet README.
1.0.0
- Introduced the observer facade, structured logging context, call-site capture and measurement primitives.
| 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
- Anarchy.Toolkit.Core (>= 1.0.6)
- Humanizer (>= 3.0.10)
- Microsoft.Extensions.Configuration.Abstractions (>= 10.0.15)
- Microsoft.Extensions.DependencyInjection.Abstractions (>= 10.0.15)
- Microsoft.Extensions.Hosting.Abstractions (>= 10.0.15)
- Newtonsoft.Json (>= 13.0.4)
- Serilog (>= 4.4.0)
- Serilog.Sinks.Console (>= 6.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.
Initial release.