Skip to content

Many Parameters: Twenty Values in the Query String ​

Benchmark · November 2026 · Many parameters

Before you trust these numbers

  • The author of NpgsqlRest runs this benchmark, and NpgsqlRest is one of the services in it.
  • The analysis was written with AI assistance from the raw data, then reviewed and edited.
  • Every test ran once, on one machine. Treat differences of a few percent as a tie.
  • Everything is public so you can check it: the code of every service, the data, and everything that went wrong, and how to run it yourself. Corrections and pull requests are welcome.
Highlight:

What this test does ​

The service receives 20 parameters in the query string (texts, integers, booleans and numerics, five of each kind in turn), passes them to a function and returns a count and a checksum. The response is tiny; the work is in parsing, converting and binding twenty values.

It is run at 50, 100 and 200 users at the same time.

The code that ran: the load script scenarios/many-params.js, the PostgreSQL function in init.sql (for the NpgsqlRest SQL file services: perf-many-params.sql), and each service's own source, linked from Every Service, One Scorecard.

How to read the charts

  • A bar is requests answered per second. Longer is faster. The fastest service is at the top.
  • A "k6 limit" or "PG limit" tag means the load generator (k6, the tool that sends the requests) or the database ran out of CPU before the service did. That service could have gone faster than its bar shows.
  • The Highlight buttons above keep one platform highlighted in every chart of the series.

What the numbers say ​

  • Go or Gin is first in every test, about 12% ahead of Bun in third place.
  • The service is the limit in almost every test here, so this is one of the cleanest comparisons of the series: twenty conversions per request is work that stays in the service.
  • Parsing parameters is where the generated APIs differ most from each other. NpgsqlRest 4.1 (JIT, SQL files) does 43,266 requests per second, PostgREST 4,143, Hasura 2,873.

Of the 93 tests on this page, the service was out of CPU in 84, the load generator in 0, PostgreSQL in 0, and nothing in 9 (in those, the number of users set the pace, not a lack of CPU). A throughput number says how much a service can carry only where the service itself was out of CPU.

Compare the services ​

Pick a test with the buttons. Choose the number of users, and what to look at: requests per second, how slow the slowest requests are, memory, or requests per CPU core. The chart starts on the main test of this kind (50 users), which the summary tables of the series use.

Users at the same time
Show
Requests per second: 50 users

↑ longer bar is betterHow many requests each service answered per second, with 50 users sending requests at the same time.

  1. 1Gin 1.12 (Go)50,908req/s
  2. 2Go 1.27 · net/http50,754req/s
  3. 3Bun 1.445,455req/s
  4. 4.NET 10 · plain Npgsql43,925req/s
  5. 5NpgsqlRest 4.1 JIT · SQL files43,266req/s
  6. 6NpgsqlRest 3.21 JIT · SQL files41,444req/s
  7. 7NpgsqlRest 4.1 JIT · functions41,129req/s
  8. 8Actix-web 4.20 (Rust)40,688req/s
  9. 9Axum 0.8 (Rust)40,309req/s
  10. 10Deno 2.940,023req/s
  11. 11NpgsqlRest 3.21 JIT · functions39,809req/s
  12. 12.NET 11 · plain Npgsql39,344req/s
  13. 13.NET 10 · Dapper38,647req/s
  14. 14NpgsqlRest 3.21 AOT · SQL files37,220req/s
  15. 15NpgsqlRest 4.1 AOT · functions37,165req/s
  16. 16Fastify 5.1237,037req/s
  17. 17NpgsqlRest 3.21 AOT · functions37,022req/s
  18. 18.NET 11 · Dapper37,020req/s
  19. 19NpgsqlRest 4.1 AOT · SQL files36,158req/s
  20. 20Express 5.326,353req/s
  21. 21NestJS 12.624,009req/s
  22. 22Swoole 6.2 (PHP)21,563req/s
  23. 23Spring Boot 4.2 (Java 25)17,658req/s
  24. 24.NET 11 · EF Core13,653req/s
  25. 25.NET 10 · EF Core12,934req/s
  26. 26PostGraphile 5.2 (GraphQL)9,483req/s
  27. 27FastAPI 0.1656,776req/s
  28. 28PostgREST 16.64,143req/s
  29. 29Hasura 2.50 (GraphQL)2,873req/s
  30. 30Django 6.12,403req/s
  31. 31Laravel Octane 13.431,639req/s

The code of this test:the script that sends the requests · the PostgreSQL function it calls · the same as a SQL file. Click a service's name (↗) to open its own code for this test.

At 50 users at the same time, Gin 1.12 (Go) is first with 50,908 requests per second, 0.3% ahead of Go 1.27 · net/http. 2 of the 31 services are within 10% of the leader, and the slowest does 1,639.

The best of each platform ​

The fastest service of every platform in the main test (50 users). "Compared with the fastest" is its requests per second as a percentage of the service in first place.

PlatformIts fastest servicePlace among the 31Requests per secondCompared with the fastestIts code
GoGin 1.12 (Go)150,908100%main.go
Bun & DenoBun 1.4345,45589%app.ts
.NET.NET 10 · plain Npgsql443,92586%Program.cs
NpgsqlRestNpgsqlRest 4.1 JIT · SQL files543,26685%appsettings.json
RustActix-web 4.20 (Rust)840,68880%main.rs
Node.jsFastify 5.121637,03773%app.js
PHPSwoole 6.2 (PHP)2221,56342%server.php
JavaSpring Boot 4.2 (Java 25)2317,65835%Application.java
GraphQLPostGraphile 5.2 (GraphQL)269,48319%graphile.config.mjs
PythonFastAPI 0.165276,77613%app.py
PostgRESTPostgREST 16.6284,1438%postgrest.conf

Every measurement of the main test ​

Latency, CPU, memory and time in PostgreSQL for all 31 services
#ServiceRequests/sMedian msp99 msCPU cores usedRequests/s per corePeak memory MBTime in PostgreSQLOut of CPU
1Gin 1.12 (Go)50,9080.702.83.5214,467323%service
2Go 1.27 · net/http50,7540.702.93.5214,439344%service
3Bun 1.445,4550.872.93.6012,6181623%service
4.NET 10 · plain Npgsql43,9250.902.63.7011,8872540%service
5NpgsqlRest 4.1 JIT · SQL files43,2660.794.63.2613,2671910%—
6NpgsqlRest 3.21 JIT · SQL files41,4440.982.63.7411,0723940%service
7NpgsqlRest 4.1 JIT · functions41,1290.854.53.2912,4981940%—
8Actix-web 4.20 (Rust)40,6881.011.93.6611,116820%service
9Axum 0.8 (Rust)40,3091.061.83.5411,379370%service
10Deno 2.940,0231.062.23.7210,7653903%service
11NpgsqlRest 3.21 JIT · functions39,8091.022.63.7310,6843670%service
12.NET 11 · plain Npgsql39,3440.914.53.3111,8922810%—
13.NET 10 · Dapper38,6470.907.03.7610,2702750%service
14NpgsqlRest 3.21 AOT · SQL files37,2200.927.93.759,9233470%service
15NpgsqlRest 4.1 AOT · functions37,1651.082.93.6610,1461180%service
16Fastify 5.1237,0371.212.23.739,9335410%service
17NpgsqlRest 3.21 AOT · functions37,0221.112.73.6610,1063050%service
18.NET 11 · Dapper37,0201.083.33.5210,5222800%service
19NpgsqlRest 4.1 AOT · SQL files36,1580.936.73.4710,4271900%service
20Express 5.326,3531.632.93.786,9646130%service
21NestJS 12.624,0091.733.03.716,4656720%service
22Swoole 6.2 (PHP)21,5632.092.73.715,8071400%service
23Spring Boot 4.2 (Java 25)17,6582.476.13.794,6631,3022%service
24.NET 11 · EF Core13,6533.057.03.753,6392940%service
25.NET 10 · EF Core12,9342.8212.53.833,3812900%service
26PostGraphile 5.2 (GraphQL)9,4834.2610.43.832,4741,1201%service
27FastAPI 0.1656,7766.899.03.911,7332960%service
28PostgREST 16.64,14311.0916.92.591,597651%—
29Hasura 2.50 (GraphQL)2,87316.9123.72.301,2512030%—
30Django 6.12,40319.3232.43.496894720%service
31Laravel Octane 13.431,63925.6958.23.824298830%service

"CPU cores used" is the average CPU of the service during the test (it may use 4). "Time in PostgreSQL" is the share of an average request that PostgreSQL spent executing the statement.

All tests of this kind ​

Requests per second of every service in every test of this kind. Each column is one test; a higher number is better.

Service50 users100 users200 users
Gin 1.12 (Go)50,90852,25451,464
Go 1.27 · net/http50,75452,70951,700
Bun 1.445,45547,04247,048
.NET 10 · plain Npgsql43,92546,44548,111
NpgsqlRest 4.1 JIT · SQL files43,26646,73345,912
NpgsqlRest 3.21 JIT · SQL files41,44442,99043,278
NpgsqlRest 4.1 JIT · functions41,12943,95243,811
Actix-web 4.20 (Rust)40,68843,32745,528
Axum 0.8 (Rust)40,30941,83746,533
Deno 2.940,02344,25546,601
NpgsqlRest 3.21 JIT · functions39,80940,18141,578
.NET 11 · plain Npgsql39,34443,31443,100
.NET 10 · Dapper38,64741,81643,027
NpgsqlRest 3.21 AOT · SQL files37,22039,03839,583
NpgsqlRest 4.1 AOT · functions37,16537,86438,522
Fastify 5.1237,03739,29440,165
NpgsqlRest 3.21 AOT · functions37,02238,13639,484
.NET 11 · Dapper37,02039,23938,777
NpgsqlRest 4.1 AOT · SQL files36,15839,86939,553
Express 5.326,35327,43128,117
NestJS 12.624,00925,01925,184
Swoole 6.2 (PHP)21,56321,64021,835
Spring Boot 4.2 (Java 25)17,65817,79617,830
.NET 11 · EF Core13,65313,91413,804
.NET 10 · EF Core12,93413,43113,516
PostGraphile 5.2 (GraphQL)9,4838,7708,792
FastAPI 0.1656,7767,1437,245
PostgREST 16.64,1434,1264,066
Hasura 2.50 (GraphQL)2,8732,7692,674
Django 6.12,4032,3112,283
Laravel Octane 13.431,6391,6381,650

Bold is the best of the column. ᵏ the load generator was out of CPU in that test and the service was not; ᵖ the same for PostgreSQL.


Previous: ← Large Payload · Next: Tables →

Comments