PowerTraces 3.0.0
dotnet add package PowerTraces --version 3.0.0
NuGet\Install-Package PowerTraces -Version 3.0.0
<PackageReference Include="PowerTraces" Version="3.0.0" />
<PackageVersion Include="PowerTraces" Version="3.0.0" />
<PackageReference Include="PowerTraces" />
paket add PowerTraces --version 3.0.0
#r "nuget: PowerTraces, 3.0.0"
#:package PowerTraces@3.0.0
#addin nuget:?package=PowerTraces&version=3.0.0
#tool nuget:?package=PowerTraces&version=3.0.0
PowerTraces
The base package for exporting OpenTelemetry traces and logs straight to a database via a connection string — no collector, no EF Core. Tables/collections are created automatically on first use.
This package is database-agnostic on its own — it defines the shapes (IStorageWriter,
IDashboardStore) and the shared exporter plumbing. To actually write anywhere, add one of the
provider packages:
| Package | Database |
|---|---|
PowerTraces.MSSQL |
SQL Server |
PowerTraces.PostgreSQL |
PostgreSQL |
PowerTraces.MongoDb |
MongoDB |
PowerTraces.MySQL |
MySQL / MariaDB |
PowerTraces.Sqlite |
SQLite (a local file, no database server) |
And to see what's collected, add PowerTraces.Dashboard
— an embedded traces/logs viewer UI you mount with one line.
Quick start
// after: dotnet add package PowerTraces.MSSQL
builder.Services.AddOpenTelemetry()
.WithTracing(t => t.AddPowerTracesMsSqlExporter(connectionString))
.WithLogging(l => l.AddPowerTracesMsSqlExporter(connectionString));
That's it — spans and logs start landing in SQL Server under the powertraces schema, tables created
automatically.
Extending to another database
Implement IStorageWriter (write side) and, if you also want dashboard support, IDashboardStore
(read side) — both defined in this package. Then either call the generic entry point directly:
tracing.AddPowerTracesExporter(new MyStorageWriter(options), options);
or package it up the same way the built-in providers do: a small AddPowerTracesMyDbExporter(...)
extension method, plus AddPowerTracesMyDbDashboard(...) registering your IDashboardStore under a
DI key so PowerTraces.Dashboard can resolve it.
Optional pieces the built-in providers all implement:
IIgnoreRuleSourceon the writer (andIIgnoreRuleStoreon the dashboard store) — the exporter then applies ignore rules created from the dashboard. Read them throughIgnoreRuleCacheso an export doesn't cost a query.IStorageWriter.DeleteTracesAsync— purges spans already written for a trace whose root turns out to be ignored.IDashboardStore.GetOverviewAsync— the Overview page's charts.
For another SQL database, most of this is already written: derive from SqlDashboardStore with
your own SqlDialect (quoting, paging, LIKE escaping, time bucketing) and reuse SqlIgnoreRules;
only the writer and the DDL are yours to write. TraceSummary.FromBatch gives you the per-trace
summary rows the shared queries read, and SqlAttributeKeys.RecordAsync keeps the attribute-key
list up to date. Your dialect's JsonAttributeText is how attribute filters read the JSON.
License
Free for any use, including commercial use, under the PowerTraces Free License (LICENSE.txt in this package): you may use it and ship it unmodified inside your applications, but not modify the code or publish changed copies.
| Product | Versions Compatible and additional computed target framework versions. |
|---|---|
| .NET | 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 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. |
-
net9.0
- OpenTelemetry (>= 1.18.0)
NuGet packages (6)
Showing the top 5 NuGet packages that depend on PowerTraces:
| Package | Downloads |
|---|---|
|
PowerTraces.Dashboard
Traces/logs viewer UI + query API for the PowerTraces exporter. Mount with app.MapPowerTracesDashboard(connectionString) — no DI registration needed, the UI is embedded in the package. |
|
|
PowerTraces.MSSQL
SQL Server provider for PowerTraces — exports traces/logs straight to SQL Server via connection string, no EF Core, tables created automatically. |
|
|
PowerTraces.PostgreSQL
PostgreSQL provider for PowerTraces — exports traces/logs straight to PostgreSQL via connection string, no EF Core, tables created automatically. |
|
|
PowerTraces.MySQL
MySQL/MariaDB provider for PowerTraces — exports traces/logs straight to MySQL via connection string, no EF Core, tables created automatically. |
|
|
PowerTraces.MongoDb
MongoDB provider for PowerTraces — exports traces/logs straight to MongoDB via connection string, no EF Core, collections/indexes created automatically. |
GitHub repositories
This package is not used by any popular GitHub repositories.
| Version | Downloads | Last Updated |
|---|---|---|
| 3.0.0 | 69 | 11/12/2026 |