LokiBulkDataProcessor 7.0.0
dotnet add package LokiBulkDataProcessor --version 7.0.0
NuGet\Install-Package LokiBulkDataProcessor -Version 7.0.0
<PackageReference Include="LokiBulkDataProcessor" Version="7.0.0" />
<PackageVersion Include="LokiBulkDataProcessor" Version="7.0.0" />
<PackageReference Include="LokiBulkDataProcessor" />
paket add LokiBulkDataProcessor --version 7.0.0
#r "nuget: LokiBulkDataProcessor, 7.0.0"
#:package LokiBulkDataProcessor@7.0.0
#addin nuget:?package=LokiBulkDataProcessor&version=7.0.0
#tool nuget:?package=LokiBulkDataProcessor&version=7.0.0
⚠️ Important Notice (v7.0.0)
This release includes a critical bug fix for Web API environments.
Previous versions (≤ 6.x) failed after the first execution unless the app was restarted.
Please upgrade to v7.0.0+ for reliable multi-execution support.
Loki Bulk Data Processor
The Loki Bulk Data Processor is a fast, efficient .NET library for bulk data inserts into SQL Server using SqlBulkCopy
. Designed for ASP.NET Core, it supports:
IEnumerable<T>
modelsDataTable
IDataReader
(v6.0.0+)JSON streams
(v6.0.0+)Structured logging and mapping support
(v6.0.0+)
Perfect for high-throughput ETL pipelines and real-time ingestion scenarios.
Install
dotnet add package LokiBulkDataProcessor
Performance
Benchmark: 100,000 records inserted into an empty SQL Server table with 4 columns (1 primary key, 1 foreign key), on a 2.7GHz i7, 16 GB RAM, SSD.
Method | Time Taken | Memory Usage |
---|---|---|
Loki Bulk Processor | 2.99 seconds | 266 MB |
Entity Framework Core | 68.74 seconds | 1 GB+ |
Inserted 100,000 records into an empty table with 1 PK and 1 FK column.
⚠️ Entity Framework was used with
AddAsync
andSaveChangesAsync
. Loki used a single bulk insert call.
Upgrade Guide
From Version | What Changed | Action Required |
---|---|---|
≤ 6.0.0 | Web API execution failed after the first request | Upgrade to v7.0.0+ ✅ |
6.0.0 | DataTableMapping renamed to DataMapping |
Update references ⚠️ |
Documentation
Everything you need to get started:
- 📝 Full Documentation (Wiki)
- 📺 YouTube Tutorial – Part 1 — Introduction & Setup
- 📺 YouTube Tutorial – Part 2 — Advanced Usage & Mapping
- 🧪 Example Projects on GitHub
Support
If this library saved you time or made your life easier, consider showing your support:
- ☕ Buy me a coffee
- ⭐ Star the GitHub repo to help others discover it
- 🗣️ Share your experience or contribute feedback via issues
Every bit helps keep the project going.
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. |
-
net8.0
- FastMember (>= 1.5.0)
- Microsoft.Extensions.DependencyInjection (>= 8.0.1)
- Microsoft.Extensions.Logging (>= 8.0.1)
- Microsoft.Extensions.Logging.Console (>= 8.0.1)
- System.Data.SqlClient (>= 4.8.6)
- Testcontainers.MsSql (>= 4.1.0)
NuGet packages
This package is not used by any NuGet packages.
GitHub repositories
This package is not used by any popular GitHub repositories.
⚠️ Critical Bug Fix: LokiBulkDataProcessor is now safe for consecutive executions in ASP.NET Core Web APIs.
Previously, only the first execution succeeded unless the app was restarted. Thanks to new internal handling, this limitation is resolved.
🆕 Improvements:
- SaveAsync methods for IDataReaders and JsonStreams
- Structured logging for better observability
🔧 Breaking Change:
- Renamed DataTableMapping to DataMapping
This update represents a major reliability milestone. If you rely on Web API scenarios, upgrade as soon as possible.