Skip to content
This repository has been archived by the owner on Feb 26, 2021. It is now read-only.

Latest benchmark figures for PostgreSQL

Shay Rojansky edited this page Feb 9, 2018 · 12 revisions

Database-only tests

! The database-only tests were run without using the private networking link, so all numbers are lower than they should be (explaining why web is faster than db)

Threads
64 96 128 256
Windows JDBC (sync) 109358 121188 123782 124397
Npgsql sync 104719 97986 91940 63892
Npgsql async 108204 108894 111277 100632
Peregrine (async) 113204 117263 120179
Linux JDBC 118588 122036 122778 123125
Npgsql sync 64249 33630 28246
Npgsql async

Web database tests

Threads
64 96 128 256
Windows Npgsql async 123284/91 124532/91 124683/91 123890/91
Npgsql sync
Peregrine (async)
Linux Npgsql async 99495 93808 100055 98615
Npgsql sync 51444 18746 6883 638
Peregrine (async)

Benchmark details

All benchmarks on the physical machines, against external database, for 2 minutes. Npgsql used perfhacks branch, bec42649e324bd39331b33e30d6800d45a1818f8.

Machines are physical Intel Xeon E5-1650 @ 3.50Ghz, 6 physical cores, 12 threads. 32GB DDR4.

Running the database-only tests

Linux JDBC:

1. ssh to aspnet@asp-perf-lin
2. If you need to build, cd to ~/roji/jdbc, the Dockerfile and benchmarking app are here.
3. docker run -it java
4. /JdbcPerfTest/out/production
5. java -cp /JdbcPerfTest/out/production/jdbc-perf-test:../../lib/HikariCP-2.7.6.jar:../../lib/slf4j-api-1.7.25.jar:../../lib/p
ostgresql-42.2.1.jar com.company.Main "jdbc:postgresql://10.0.0.103/hello_world?user=benchmarkdbuser&password=****" <threads> <seconds>

Linux ADO:

1. ssh to aspnet@asp-perf-lin
2. If you need to build, cd to ~/roji/ado, the Dockerfile and benchmarking app are here.
3. docker run -t roji-ado
4. cd /AdoPerfTest/ado-perf-test
5. dotnet run -c Release "Server=10.0.0.103;Database=hello_world;User Id=benchmarkdbuser;Password=*****;Maximum Pool Size=1024;NoResetOnClose=true" <threads> <seconds> <sync or async>

Linux web cmdline:

dotnet.exe run --server "http://asp-perf-lin:5001" --client "http://asp-perf-load:5002" --jobs ../Benchmarks/benchmarks.html.json -n DbFortunesRaw --database PostgreSql --webHost KestrelSockets --repository "https://github.com/roji/benchmarks@perfhacks" --duration 120 --clientThreads 256