Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/jfelipearaujo/poc_dapper_postgres
https://github.com/jfelipearaujo/poc_dapper_postgres
Last synced: 6 days ago
JSON representation
- Host: GitHub
- URL: https://github.com/jfelipearaujo/poc_dapper_postgres
- Owner: jfelipearaujo
- Created: 2022-04-02T18:41:48.000Z (almost 3 years ago)
- Default Branch: master
- Last Pushed: 2022-04-03T16:42:35.000Z (almost 3 years ago)
- Last Synced: 2024-05-02T04:44:36.694Z (8 months ago)
- Language: C#
- Size: 19.5 KB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# PoC: Dapper + Postgres
This repository is an example of a reusable code using Dapper and Postgres
Installed packages:
- Dapper (2.0.123)
- Dapper.Contrib (2.0.78)
- Dapper.FluentMap (2.0.0)
- Dapper.FluentMap.Dommel (2.0.0)
- DotNet.Testcontainers (1.5.0)
- Microsoft.Extensions.DependencyInjection (3.1.23)
- Npgsql (6.0.3)
- PostgreSQLCopyHelper (2.8.0)
- SqlKata (2.3.7)
- SqlKata.Execution (2.3.7)When executed, the application creates a container running postegres and when it finishes, it destroys the container.
This example includes:
- Insert one entity
- Insert many entities
- Bulk insert
- Get count
- Get one entity
- Get all entities
- Update
- DeleteExample of bulk insert runtimes:
| Num of items | Total time |
| ------------ | ---------- |
| 1000 | 00:00:00.0745338 |
| 2000 | 00:00:00.0092279 |
| 3000 | 00:00:00.0155983 |
| 4000 | 00:00:00.0155983 |
| 5000 | 00:00:00.0603322 |
| 6000 | 00:00:00.0186088 |
| 7000 | 00:00:00.0177428 |
| 8000 | 00:00:00.0585876 |
| 9000 | 00:00:00.0237423 |
| 10000 | 00:00:00.0381435 |