From 8061f5a5e868693b0bbb4bf1542f4c7a661c497b Mon Sep 17 00:00:00 2001 From: yamelsenih Date: Fri, 20 Sep 2024 14:37:04 -0400 Subject: [PATCH] Validate Maximum Pool Size references: https://github.com/solop-develop/adempiere-grpc-server/issues/801 --- .../{DatabaseConfig.java => BackendDatabaseConfig.java} | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) rename src/main/java/org/spin/server/config/{DatabaseConfig.java => BackendDatabaseConfig.java} (98%) diff --git a/src/main/java/org/spin/server/config/DatabaseConfig.java b/src/main/java/org/spin/server/config/BackendDatabaseConfig.java similarity index 98% rename from src/main/java/org/spin/server/config/DatabaseConfig.java rename to src/main/java/org/spin/server/config/BackendDatabaseConfig.java index f996bc9..4180b08 100644 --- a/src/main/java/org/spin/server/config/DatabaseConfig.java +++ b/src/main/java/org/spin/server/config/BackendDatabaseConfig.java @@ -21,7 +21,7 @@ * @author Yamel Senih * */ -public class DatabaseConfig { +public class BackendDatabaseConfig { public static final String CONFIG_DB_IDLE_TIMEOUT = "DB|CONFIG_DB_IDLE_TIMEOUT"; public static final String CONFIG_DB_MINIMUM_IDLE = "DB|CONFIG_DB_MINIMUM_IDLE"; public static final String CONFIG_DB_MAXIMUM_POOL_SIZE = "DB|CONFIG_DB_MAXIMUM_POOL_SIZE"; @@ -55,7 +55,7 @@ public static void setMinimumIdle(int value) { } public static void setMaximumPoolSize(int value) { - if(value >= 0) { + if(value > 0) { Ini.setProperty(CONFIG_DB_MAXIMUM_POOL_SIZE, String.valueOf(value)); } }