From 80c134678f3d1bb54cd690a56c79a4231c1d8b4a Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Renner=20G=C3=A1bor?= Date: Thu, 17 Aug 2023 17:14:05 +0200 Subject: [PATCH] Query rate calculation corrected in README.md --- README.md | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/README.md b/README.md index fb929bc..32a7ea1 100644 --- a/README.md +++ b/README.md @@ -116,9 +116,9 @@ A spring boot application with a service taking 50ms to complete a database quer #### Connection Pool Size * `spring.datasource.hikari.maximum-pool-size` - * `50ms/database query` => `200 database queries/sec` per connection - * If `pool size = 10 connections` on a single app instance, then we can handle `200 X 10 = 2000 queries/sec` per instance. - * if we scale the apps instance to 20, we can handle `2000 x 20 = 40,000 queries/sec` among 20 instances, by using `10 x 20 = 200 connections` + * `50ms/database query` => `20 database queries/sec` per connection + * If `pool size = 10 connections` on a single app instance, then we can handle `20 X 10 = 200 queries/sec` per instance. + * if we scale the apps instance to 20, we can handle `200 x 20 = 4,000 queries/sec` among 20 instances, by using `10 x 20 = 200 connections` Keeping `pool size <= 10 connections` per app instance and _sensible_ app instance scaling to keep the `total db connections < 1000` across all app instances (_especially for Oracle_) results in minimizing the _noisy neighbour_ impacts in PCF.