CDS.Core
1.0.1
dotnet add package CDS.Core --version 1.0.1
NuGet\Install-Package CDS.Core -Version 1.0.1
<PackageReference Include="CDS.Core" Version="1.0.1" />
<PackageVersion Include="CDS.Core" Version="1.0.1" />
<PackageReference Include="CDS.Core" />
paket add CDS.Core --version 1.0.1
#r "nuget: CDS.Core, 1.0.1"
#:package CDS.Core@1.0.1
#addin nuget:?package=CDS.Core&version=1.0.1
#tool nuget:?package=CDS.Core&version=1.0.1
π CDS β Central Debug System
A structured, real-time debug signal system for .NET β built for developers and AI-assisted debugging.
π§ Why CDS?
Traditional debugging is broken:
- β Noisy output windows
- β Unstructured logs
- β Important signals get buried
π CDS turns your app into a signal-driven system:
- Emit structured debug signals
- Observe them in a real-time UI
- Route them to file or custom sinks
- Analyze without stopping execution
β‘ 30-Second Setup (Deterministic)
1. Install
Install-Package CDS.Core
Install-Package CDS.Wpf
2. Enable CDS (REQUIRED)
π Place inside: App.xaml.cs β OnStartup
using CDS.Core.Diagnostics;
using CDS.Wpf.Sinks;
private FileDebugSink _fileSink;
protected override void OnStartup(StartupEventArgs e)
{
base.OnStartup(e);
// β
Enable CDS
DebugConfig.Enabled = true;
// β
Optional but recommended (file logging)
_fileSink = new FileDebugSink();
DebugBus.RegisterSink(_fileSink);
// β
Sanity check
DebugBus.Emit("System", DebugLevel.Info, "CDS Initialized", "App");
}
π Optional cleanup:
protected override void OnExit(ExitEventArgs e)
{
_fileSink?.Stop();
base.OnExit(e);
}
3. Add Debug Panel (REQUIRED)
xmlns:cds="clr-namespace:CDS.Wpf.Views;assembly=CDS.Wpf"
<cds:DebugPanelView />
π The UI automatically connects to the signal stream.
4. Emit Signals Anywhere
DebugBus.Emit("UI", DebugLevel.Info, "Button clicked");
β Expected Result
If setup is correct, you will get:
- π΄ Live debug stream in UI
- π΅ Auto-scroll + high-performance rendering
- π‘ Filtering (level, category, search)
- π§ Duplicate grouping (xN)
- βΈοΈ Pause β inspect β resume (with buffered replay)
- π File logging (if enabled)
π§ Mental Model (Important)
CDS has two independent pipelines:
1. Signal Pipeline (Core)
DebugBus.Emit β Sinks (file, etc.)
2. Observation Pipeline (UI)
DebugPanelView β Collector β Live UI
π You explicitly wire the system. Nothing is hidden.
π§ Debug Configuration
Default behavior:
- β DEBUG β enabled automatically
- π RELEASE β disabled unless configured
Enable in production:
DebugConfig.Enabled = true;
OR:
APP_DEBUG=1
π File Logging (Optional but Recommended)
var fileSink = new FileDebugSink();
DebugBus.RegisterSink(fileSink);
π Logs are saved to:
%LOCALAPPDATA%\CDS\
π§ Structured Signals (Advanced)
DebugBus.Emit(new DebugEvent
{
Category = "Network",
Level = DebugLevel.Warning,
Message = "Slow response",
Source = "ApiClient",
SubCategory = "Latency",
Data =
{
["DurationMs"] = 1200,
["Endpoint"] = "/users"
}
});
β οΈ Important Notes
π΄ CDS disabled in Release
If nothing shows:
DebugConfig.Enabled = true;
π΄ WPF Required for UI
DebugPanelView requires a WPF app (Application.Current.Dispatcher).
π΄ Pause Behavior (Key Feature)
Pause does NOT stop logging.
- Signals continue flowing
- UI freezes for inspection
- On resume β buffered signals replay in order
π Zero data loss.
π§ Best Practices
- β Use meaningful categories (
UI,Data,Network) - β Use
Sourcefor origin tracking - β Use
Datafor structured insights (AI-friendly) - β Use
DebugThrottlefor high-frequency logs - β Think in signals, not logs
ποΈ Architecture
Your Code
β
DebugBus.Emit(...)
β
βββββββββββββββ
Signal Pipeline
βββββββββββββββ
β
Sinks (File, future extensions)
β
βββββββββββββββ
Observation Pipeline
βββββββββββββββ
β
DebugPanelView (UI)
π₯ Core Idea
CDS is not a logger. It is a real-time signal system for your application.
π License
MIT
| Product | Versions Compatible and additional computed target framework versions. |
|---|---|
| .NET Framework | net472 is compatible. net48 was computed. net481 was computed. |
-
.NETFramework 4.7.2
- No dependencies.
NuGet packages (1)
Showing the top 1 NuGet packages that depend on CDS.Core:
| Package | Downloads |
|---|---|
|
CDS.Wpf
CDS WPF provides a real-time debug panel UI for CDS.Core. |
GitHub repositories
This package is not used by any popular GitHub repositories.