EricksonLopez.DapperExtensions Overview
EricksonLopez.DapperExtensions (2.0.0 on NuGet, L3) extends Dapper across PostgreSQL, SQL Server, MariaDB, MySQL, Oracle, and SQLite with explicit IUnitOfWork savepoints, BulkParameters + UNNEST batching, keyed IResiliencePipeline fault tolerance, and Roslyn [SqlEntity] source-generated IDataReader parsers.
- Atomic transaction and savepoint lifecycle:
BeginUnitOfWorkAsyncandWithUnitOfWorkAsyncbind Dapper commands to an explicitDbTransactionwith savepoints (ISavepoint) and strict post-rollback/non-DbTransactionguards. - High-throughput PostgreSQL
UNNESTbatching:BulkParameters.From(items)decomposes object graphs into typedNpgsqlParameterarrays forBulkInsertAsyncwithout reflection. - Zero-reflection
[SqlEntity]mapping:EricksonLopez.DapperExtensions.SourceGeneratorsemitsReadFromDataReaderandGetMultiMapReaderFactorysoMultiMapBuilder<T>avoids runtimeILemit in Native AOT hosts. - Consolidation of
dapper-extensions-pg: Supersedes the legacydapper-extensions-pgrepository with unified2.0.0dialect packages.
Rendering diagram…
flowchart LR App["Caller / Repository"] --> UoW["IUnitOfWork + ISavepoint"] UoW --> Res["Keyed IResiliencePipeline (postgresql/sqlserver/...)"] Res --> Bulk["BulkParameters UNNEST / MultiMapBuilder"] Bulk --> DB["PostgreSQL / SQL Server / MySQL / MariaDB / Oracle / SQLite"]
View accessible text summary and structure
Application code enters WithUnitOfWorkAsync or BulkParameters, routes through keyed IResiliencePipeline transient detectors, and executes parameterized ADO.NET or UNNEST commands on the target database provider.
flowchart LR
App["Caller / Repository"] --> UoW["IUnitOfWork + ISavepoint"]
UoW --> Res["Keyed IResiliencePipeline (postgresql/sqlserver/...)"]
Res --> Bulk["BulkParameters UNNEST / MultiMapBuilder"]
Bulk --> DB["PostgreSQL / SQL Server / MySQL / MariaDB / Oracle / SQLite"]Package Roster & Native AOT Status (11 / 12 Published)
Section titled “Package Roster & Native AOT Status (11 / 12 Published)”11 of 12 packages are published at 2.0.0 on NuGet (2,036 total downloads; localVersion: 3.1.0 on disk), while EricksonLopez.DapperExtensions.Analyzers remains unpublished (3.1.0 local only). Overall AOT status is Full (10 Full, 0 Incompatible, 2 NotApplicable Roslyn tools):
| Package | NuGet (2.0.0) |
AOT Status | TFMs | Role |
|---|---|---|---|---|
EricksonLopez.DapperExtensions |
Published (297 dl) |
Full |
net8.0;net9.0;net10.0 |
IUnitOfWork, ISavepoint, MultiMapBuilder<T>, SqlResilienceDefaults, [SqlEntity] |
EricksonLopez.DapperExtensions.PostgreSql |
Published (472 dl) |
Full |
net8.0;net9.0;net10.0 |
BulkParameters, BulkInsertAsync, PagedQueryExtensions, NpgsqlTypeHandlerRegistrar |
EricksonLopez.DapperExtensions.DependencyInjection |
Published (155 dl) |
Full |
net8.0;net9.0;net10.0 |
AddDapperExtensions, AddDapperTypeHandlers, AddDapperResiliencePipelines |
EricksonLopez.DapperExtensions.HealthChecks |
Published (144 dl) |
Full |
net8.0;net9.0;net10.0 |
AddDapperHealthCheck + per-dialect health checks |
EricksonLopez.DapperExtensions.OpenTelemetry |
Published (133 dl) |
Full |
net8.0;net9.0;net10.0 |
AddDapperOpenTelemetry (ActivitySource: EricksonLopez.DapperExtensions) |
EricksonLopez.DapperExtensions.MariaDb |
Published (151 dl) |
Full |
net8.0;net9.0;net10.0 |
MariaDB bulk/pagination/type handlers |
EricksonLopez.DapperExtensions.Oracle |
Published (149 dl) |
Full |
net8.0;net9.0;net10.0 |
Oracle bulk/pagination/type handlers |
EricksonLopez.DapperExtensions.SqlServer |
Published (134 dl) |
Full |
net8.0;net9.0;net10.0 |
SQL Server TVP/bulk/pagination/type handlers |
EricksonLopez.DapperExtensions.MySql |
Published (130 dl) |
Full |
net8.0;net9.0;net10.0 |
MySQL bulk/pagination/type handlers |
EricksonLopez.DapperExtensions.Sqlite |
Published (130 dl) |
Full |
net8.0;net9.0;net10.0 |
SQLite bulk/pagination/type handlers |
EricksonLopez.DapperExtensions.SourceGenerators |
Published (141 dl) |
NotApplicable |
netstandard2.0 |
Roslyn [SqlEntity] IDataReader mapper generator |
EricksonLopez.DapperExtensions.Analyzers |
Unpublished | NotApplicable |
netstandard2.0 |
Local 3.1.0 only (EL_DAP001 NoDynamicDapperAnalyzer) |
benchmarks.json contains 1 entry from EricksonLopez.DapperExtensions.PostgreSql.Benchmarks.BulkInsertBenchmarks-report-github.md (.NET 10.0.12 X64 RyuJIT x86-64-v4), and its sole row (Row-by-row INSERT) recorded status: "na_error" (Mean = NA). Consequently, there are 0 verified measured BenchmarkDotNet rows in the snapshot; throughput claims are withheld until valid BenchmarkDotNet measurements are published.