RSEV.Utilities
2.0.0
dotnet add package RSEV.Utilities --version 2.0.0
NuGet\Install-Package RSEV.Utilities -Version 2.0.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="RSEV.Utilities" Version="2.0.0" />
For projects that support PackageReference, copy this XML node into the project file to reference the package.
<PackageVersion Include="RSEV.Utilities" Version="2.0.0" />
<PackageReference Include="RSEV.Utilities" />
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 RSEV.Utilities --version 2.0.0
The NuGet Team does not provide support for this client. Please contact its maintainers for support.
#r "nuget: RSEV.Utilities, 2.0.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 RSEV.Utilities@2.0.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=RSEV.Utilities&version=2.0.0
#tool nuget:?package=RSEV.Utilities&version=2.0.0
The NuGet Team does not provide support for this client. Please contact its maintainers for support.
RSEV.Utilities
A universal, extensible, and future-proof .NET framework for plugins, controllers, modules, and system services.
RSEV.Utilities is a modular utility framework that provides developers with a stable foundation for building complex applications, services, or plugin systems.
It combines clarity, extensibility, and architectural purity — with the goal of removing barriers and enabling productive development.
Features
Universal RuntimeContext
- Global configuration (
IConfig) - AssemblyLoader for dynamic plugin loading
- TypeDiscovery for automatic type detection
- PluginRegistry for activating/deactivating plugins
- MessageBusRegistry for registering and constructing custom message buses
- GlobalState for system-wide states
- Integrated logger (
ILogger)
Lifecycle System
IOnStart/IOnStartAsyncIOnStop/IOnStopAsyncIFirstRunfor one-time initialization- Clean separation of start, stop, and setup logic
Logging System
SystemLogas an extensible standard logger- Log rotation
- Colored console output
- Log levels: Debug, Info, Warning, Error, Critical
- Replaceable via
ILogger
Stable Shutdown & Error Handling
UnexpectedExitHandlerfor controlled shutdown on errorsShutdownSummaryfor diagnostics and logging- Recommendation to use custom
IOnStopimplementations
Plugin & Module Architecture
- Dynamic loading of external assemblies
- Automatic discovery of controllers, plugins, and services
- Extensible without modifying the core system
Event & Messaging Templates
IEventHandler<TEventArgs>/BaseEventHandler<TEventArgs>for event processingIEventListener<TEventArgs>/BaseEventListener<TEventArgs>for event receptionIEvent<TEventArgs>for event type definitions with metadataIEventRegistry<TEventArgs>/EventRegistry<TEventArgs>for event registration and publishingIEventBus/BaseEventBusfor centralized multi-registry event bus implementationsIMessageBus/BaseMessageBusfor custom message-bus implementationsMessageBusRegistryfor registering, loading, and managing message buses
Flexible Event Registration
- Register events independently without message bus binding
- Alternatively, create custom EventBus implementations and register via MessageBusRegistry
- Thread-safe handler and listener subscription/unsubscription
- Synchronous and asynchronous event publishing
- Framework users can extend with just 1-3 lines in custom RuntimeContext
Process Management
RuntimeProcessControllerfor centralized subprocess lifecycle managementIRuntimeSubprocessinterface for subprocess contracts with exit codes and state tracking- Process implementations:
DotNetProcess,NodeProcess,ShellProcess,ExecutableProcess,PythonProcess - Cross-platform executable resolution via
ExecutableResolverutility - Event-driven stdout/stderr handling with automatic log classification
- Generic health checks (
CheckHealthAsync) with process-type-specific overrides - Process-specific log level classification (
ProcessLogLevel: Info, Warning, Error) - Thread-safe process registry with discovery by name or state
ApiBuilder (Lightweight API Host)
RuntimeApiHost– a framework-native TCP-based API host, independent of ASP.NET CoreIRuntimeEndpoint/BaseRuntimeEndpointfor defining routed endpoints with anOnHandleAsynchookRuntimeEndpointControllerfor thread-safe endpoint registration and route resolutionEndpointRequest/EndpointResponsemodels for request/response handling- Manual HTTP/1.1-style parsing (request line, headers, Content-Length body) over raw TCP sockets
- Automatic exception handling: unhandled endpoint exceptions are converted to HTTP 500 responses
- TLS-ready via a reusable
Networking.Securitylayer (TlsOptions,TlsStreamFactory) using only built-inSystem.Net.Security/System.Security.Cryptographyclasses - TLS layer is protocol-agnostic and can be reused by other framework components beyond ApiBuilder
RuntimeClient (Request Builder & API Client)
RuntimeApiClient– high-level client counterpart toRuntimeApiHost, handling transport, requests, and sessionsRuntimeRequestBuilder– fluent builder (WithRoute,WithPayload,WithHeader,BindSession,Build,BuildBytes) producing HTTP/1.1-compatible byte payloads consumable directly byRuntimeApiHostRuntimeRequest/RuntimeResponsemodels with automatic error detection (IsError) based on status codeRuntimeSessionfor binding session state to requests, with an extensibleRenewAsynchook for automatic session renewalTcpTransport/TcpConnectionfor raw TCP connectivity with optional TLS, reusing the existingNetworking.SecuritylayerTlsSettings– client-facing TLS configuration model that maps onto the sharedTlsOptions- Automatic 500-error recognition and JSON payload serialization via
System.Text.Json
Installation
dotnet add package RSEV.Utilities
| Product | Versions Compatible and additional computed target framework versions. |
|---|---|
| .NET | 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 was computed. 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 was computed. 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.
-
net8.0
- No dependencies.
NuGet packages
This package is not used by any NuGet packages.
GitHub repositories
This package is not used by any popular GitHub repositories.