CasCap.Common.Abstractions 4.17.0

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

CasCap.Common.Abstractions

Shared contracts for .NET configuration, background features, caching, notifications, event sinks and telemetry.

Installation

dotnet add package CasCap.Common.Abstractions

Target frameworks: netstandard2.0, net8.0, net9.0, net10.0

Usage

Implement IAppConfig to give a configuration type a section name. On .NET 8+, the interface requires that static property:

using CasCap.Common.Abstractions;

public sealed record ExampleConfig : IAppConfig
{
    public static string ConfigurationSectionName => "Example";
    public bool Enabled { get; init; }
}

This package supplies contracts and shared models; it does not load application configuration or start background features by itself. Use CasCap.Common.Configuration for binding and CasCap.Common.Services for feature execution.

Public Contracts

Interface Description
IAppConfig Application options contract with a section name on .NET 8+
IBgFeature Named background feature with FeatureName and ExecuteAsync
IEventSink<T> Event write path, initialization and housekeeping for reference or value types
ILocalCache Local cache get, set and deletion operations
INotifier Notification send/receive operations
INotificationMessage, INotificationAttachment, INotificationGroup, INotificationResponse, IReceivedNotification Notification payload and result contracts
ICommsEventFormatter, ICommsGroupRouter Communication-event formatting and routing; .NET 8+ only
IHttpAuditStore HTTP audit persistence; .NET 8+ only
IMyBlob Blob data and metadata
IAzBlobStorageConfig, IAzTableStorageConfig Azure storage configuration contracts
IKubeAppConfig, IMetricsConfig Host identity and telemetry configuration

Shared Models

Type Description
KubernetesProbeTypes Flags for readiness, liveness and startup probes
CommsEvent Communication event with source, timestamp, message and optional JSON payload
MediaReference Cached-media pointer; .NET 8+ only
HttpAuditEntry HTTP request/response audit record; .NET 8+ only
ApiAuthConfig Required basic-auth username/password and anonymous path prefixes; .NET 8+ only
SinkConfig, SinkConfigParams, SinkSettingKeys Sink selection and settings; .NET 8+ only

Probe tag conversion is supplied by CasCap.Common.Extensions.Diagnostics.HealthChecks, not this package.

Event Sink Registration

On .NET 8+, decorate sink implementations with [SinkType("Console")], enable the matching AvailableSinks entry, and call services.AddEventSinks<TEvent>(sinkConfig, assemblies). Registration discovers implementations; it does not dispatch events. The application resolves the registered IEventSink<TEvent> instances and invokes their write methods.

The write-path contract is:

string SinkType { get; }
Task InitializeAsync(CancellationToken cancellationToken);
Task WriteEvent(T @event, CancellationToken cancellationToken = default);
Task HousekeepingAsync(IReadOnlyCollection<string> validIds, CancellationToken cancellationToken = default);

SinkType should match the attribute's name. On .NET 8+, initialization and housekeeping have default no-op implementations. On .NET Standard 2.0, implement all interface methods explicitly.

An application can define additional query interfaces in a CasCap namespace. AddEventSinks registers those interfaces against the enabled QuerySinkType when supported by that sink, otherwise the last registered compatible sink. The "Primary" keyed alias identifies the selected query sink. Every sink enabled in the registration remains available through the write-path enumeration; query-capable fallback registrations from earlier calls may be replaced.

Configuration Examples

The application chooses the section name and binds SinkConfig; registration does not bind it automatically or supply concrete sink implementations.

One Enabled Sink

{
  "Sinks": {
    "AvailableSinks": {
      "Console": { "Enabled": true }
    }
  }
}

Write to Multiple Sinks with a Preferred Query Sink

{
  "Sinks": {
    "QuerySinkType": "Redis",
    "AvailableSinks": {
      "Console": { "Enabled": true },
      "Redis": { "Enabled": true }
    }
  }
}

ApiAuthConfig binds under CasCap:ApiAuthConfig; its Username and Password must be non-empty. Supply them through a secret provider. AnonymousPathPrefixes defaults to ["/healthz"].

Product Compatible and additional computed target framework versions.
.NET net5.0 was computed.  net5.0-windows was computed.  net6.0 was computed.  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 is compatible.  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.  net9.0 is compatible.  net9.0-android was computed.  net9.0-browser was computed.  net9.0-ios was computed.  net9.0-maccatalyst was computed.  net9.0-macos was computed.  net9.0-tvos was computed.  net9.0-windows was computed.  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. 
.NET Core netcoreapp2.0 was computed.  netcoreapp2.1 was computed.  netcoreapp2.2 was computed.  netcoreapp3.0 was computed.  netcoreapp3.1 was computed. 
.NET Standard netstandard2.0 is compatible.  netstandard2.1 was computed. 
.NET Framework net461 was computed.  net462 was computed.  net463 was computed.  net47 was computed.  net471 was computed.  net472 was computed.  net48 was computed.  net481 was computed. 
MonoAndroid monoandroid was computed. 
MonoMac monomac was computed. 
MonoTouch monotouch was computed. 
Tizen tizen40 was computed.  tizen60 was computed. 
Xamarin.iOS xamarinios was computed. 
Xamarin.Mac xamarinmac was computed. 
Xamarin.TVOS xamarintvos was computed. 
Xamarin.WatchOS xamarinwatchos was computed. 
Compatible target framework(s)
Included target framework(s) (in package)
Learn more about Target Frameworks and .NET Standard.

NuGet packages (11)

Showing the top 5 NuGet packages that depend on CasCap.Common.Abstractions:

Package Downloads
CasCap.Common.Net

Helper library for common HttpClient/WebAPI requirements.

CasCap.Common.Caching

Helper library for local and remote object caching.

CasCap.Common.Extensions.Diagnostics.HealthChecks

Custom ASP.NET Core health check base classes for monitoring HTTP endpoint availability.

CasCap.Common.Services

Feature-flag background service launcher using bitwise EnabledFeatures flags to activate IFeature implementations.

CasCap.Common.Configuration

Configuration bootstrapping helpers — standard IConfiguration pipeline setup and validated IOptions binding for IAppConfig records.

GitHub repositories

This package is not used by any popular GitHub repositories.

Version Downloads Last Updated
4.17.0 0 10/24/2026
4.16.0 322 10/21/2026
4.15.0 327 10/6/2026
4.14.4 520 10/4/2026
4.14.3 319 9/28/2026
4.14.2 520 9/25/2026
4.14.1 580 9/23/2026
4.14.0 882 9/19/2026
4.13.0 277 9/15/2026
4.12.8 619 9/10/2026
4.12.7 603 9/4/2026
4.12.6 344 9/1/2026
4.12.5 418 8/20/2026
4.12.4 597 8/18/2026
4.12.3 585 7/15/2026
4.12.2 571 6/26/2026
4.12.1 542 6/14/2026
4.12.0 618 6/12/2026
4.11.9 541 6/10/2026
4.11.8 515 5/27/2026
Loading failed