-
Notifications
You must be signed in to change notification settings - Fork 19
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Test with pgbench and debug issues #342
Comments
The above issues are resolved and this is the results of testing GatewayD with pgbench. Based on the following results, the average latency was increased by 41.91 ms, which is consistent with my benchmarks with These tests were run on my development machine, which is a small laptop with 2 cores and 4 threads, so I don't expect much of it. I will run bigger tests on more powerful machines on AWS using k6 (#145, #188). k6 (and xk6-sql) tests are more reliable and various metrics are emitted, which can be further scraped and visualized by Prometheus and Grafana. It is important to note that running pgbench in initialization mode ( GatewayDGATEWAYD_POOLS_DEFAULT_SIZE=50 ./gatewayd run
2023-10-26T23:33:31+02:00 INF Starting plugin health check scheduler healthCheckPeriod=5s
2023-10-26T23:33:31+02:00 INF Metrics are exposed address=http://localhost:9090/metrics
2023-10-26T23:33:31+02:00 INF There are clients available in the pool count=50 name=default
2023-10-26T23:33:31+02:00 INF Started the client health check scheduler healthCheckPeriod=1m0s startDelay=2023-10-26T23:34:31+02:00
2023-10-26T23:33:31+02:00 INF GatewayD is listening address=0.0.0.0:15432
2023-10-26T23:33:31+02:00 INF Started the HTTP API address=localhost:18080
2023-10-26T23:33:31+02:00 INF Started the gRPC API address=localhost:19090 network=tcp
2023-10-26T23:33:31+02:00 INF GatewayD is running pid=80321
2023-10-26T23:33:36+02:00 ERR No more available connections
2023-10-26T23:33:36+02:00 ERR Failed to connect to the client error="pool is exhausted" PgBench <=> PostgreSQLPGPASSWORD=postgres pgbench -M extended --transactions 1 --jobs 1 --client 50 -h localhost -p 5432 -U postgres postgres
pgbench (15.4 (Debian 15.4-3))
starting vacuum...end.
transaction type: <builtin: TPC-B (sort of)>
scaling factor: 1
query mode: extended
number of clients: 50
number of threads: 1
maximum number of tries: 1
number of transactions per client: 1
number of transactions actually processed: 50/50
number of failed transactions: 0 (0.000%)
latency average = 131.112 ms
initial connection time = 664.919 ms
tps = 381.353347 (without initial connection time) PgBench <=> GatewayD <=> PostgreSQLPGPASSWORD=postgres pgbench -M extended --transactions 1 --jobs 1 --client 50 -h localhost -p 15432 -U postgres postgres
pgbench (15.4 (Debian 15.4-3))
starting vacuum...end.
transaction type: <builtin: TPC-B (sort of)>
scaling factor: 1
query mode: extended
number of clients: 50
number of threads: 1
maximum number of tries: 1
number of transactions per client: 1
number of transactions actually processed: 50/50
number of failed transactions: 0 (0.000%)
latency average = 186.067 ms
initial connection time = 680.196 ms
tps = 268.720407 (without initial connection time) |
PgBench log
PostgreSQL log
GatewayD log
Related
The text was updated successfully, but these errors were encountered: