TSLAppLogger 3.1.0
dotnet add package TSLAppLogger --version 3.1.0
NuGet\Install-Package TSLAppLogger -Version 3.1.0
<PackageReference Include="TSLAppLogger" Version="3.1.0" />
<PackageVersion Include="TSLAppLogger" Version="3.1.0" />
<PackageReference Include="TSLAppLogger" />
paket add TSLAppLogger --version 3.1.0
#r "nuget: TSLAppLogger, 3.1.0"
#:package TSLAppLogger@3.1.0
#addin nuget:?package=TSLAppLogger&version=3.1.0
#tool nuget:?package=TSLAppLogger&version=3.1.0
TSLAppLogger
A production-safe, non-blocking logging library for .NET Framework 4.8, designed for Windows Services, * telecom systems*, and long-running backend applications.
TSLAppLogger is built with one rule above all others:
Logging must never impact application stability.
๐ Quick Start
Install via NuGet
Install-Package TSLAppLogger
dotnet add package TSLAppLogger
๐ฆ Package Information
- Package Name: TSLAppLogger
- Version: 3.1
- Target Framework: .NET Framework 4.8
โจ Key Features
- Asynchronous, non-blocking logging
- Logger APIs never throw exceptions
- Safe for Windows Services and always-on systems
- File-based logging with automatic fallback
- Windows Event Log support for critical failures
- Emergency logging when file logging is unavailable
- Service lifecycle logging (start / stop / fatal)
- Minimal CPU and memory overhead
๐ง Design Philosophy
TSLAppLogger is designed for worst-case production scenarios:
- Logging failures are silently handled
- Application execution is never interrupted
- Safe to use in:
- try / catch blocks
- Startup code
- Shutdown paths
- Crash handling logic
๐งฉ Initialization
Initialize the logger once during application or service startup.
TSLAppLogger.Initialize();
Notes
- Safe to call multiple times
- Does not block
- Does not throw exceptions
๐ Writing Logs
TSLAppLogger.Debug("Debug message");
TSLAppLogger.Info("Application started");
TSLAppLogger.Warn("Configuration file missing, using defaults");
TSLAppLogger.Error("Operation failed");
TSLAppLogger.Fatal("Critical failure");
All logging calls:
- Are asynchronous
- Never throw
- Never block the calling thread
๐งฏ Logging Exceptions
Logging exceptions is safe and recommended.
try
{
ProcessRequest();
}
catch (Exception ex)
{
TSLAppLogger.Error("Unhandled exception occurred", ex);
}
- Full exception details are logged
- Application flow is never affected
๐ช Windows Service Usage
TSLAppLogger is optimized for Windows Services.
Service Start
protected override void OnStart(string[] args)
{
TSLAppLogger.Initialize();
TSLAppLogger.Info("Service started");
}
Service Stop
protected override void OnStop()
{
TSLAppLogger.Info("Service stopped");
}
Fatal Service Error
catch (Exception ex)
{
TSLAppLogger.Fatal("Service crashed", ex);
}
๐ชต Log Output
Default Locations
Application Logs
- Standard operational logs
ServiceEventLogs
- Service lifecycle events
- Emergency and fallback logs
- Fatal failures
Each entry includes:
- Timestamp
- Machine name
- Process ID
Directories are created automatically if missing.
๐ช Windows Event Log
For critical scenarios, logs may also be written to the Windows Event Log:
- Service startup failures
- Fatal runtime errors
- Emergency fallback conditions
Event log writes are safe and non-blocking.
๐ก๏ธ Reliability Guarantees
- Logger never throws exceptions
- Logging failures never stop the application
- Automatic fallback when file logging fails
- Safe during startup, runtime, and shutdown
Logging will never be the reason your application fails.
โ๏ธ Performance
- Fully asynchronous
- Minimal locking
- Low memory allocation
- Safe for high-throughput, multi-threaded systems
๐ฏ Recommended Use Cases
- Windows Services
- Telecom and network systems
- Background workers
- Long-running backend processes
- Mission-critical production applications
๐งพ Summary
TSLAppLogger is a production-first logging library focused on:
- Stability
- Predictability
- Safety
If your system must stay online no matter what, TSLAppLogger is built for that.
| Product | Versions Compatible and additional computed target framework versions. |
|---|---|
| .NET Framework | net48 is compatible. net481 was computed. |
-
.NETFramework 4.8
- 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.