We have an application with 2000-3000 concurrent users. When the system is under load we are getting Timeout waiting for connection from pool. This appears to be http connection pool and not database connection pool. Any thoughts or guidance is appreciated. Timeout waiting for connection from pool 2022-04-22T15:09:07.396383 [APP/PROC/WEB/0] at BulkInventorySearch.SUB_InvokeBulkSearchAPI (CallRest : 'Call REST (POST)') 2022-04-22T15:09:07.396608 [APP/PROC/WEB/0] Advanced stacktrace: 2022-04-22T15:09:07.396757 [APP/PROC/WEB/0] java.security.PrivilegedActionException: org.apache.http.conn.ConnectionPoolTimeoutException: Timeout waiting for connection from pool 2022-04-22T15:09:07.396936 [APP/PROC/WEB/0] at com.mendix.integration.actions.microflow.RestCallAction.execute(RestCallAction.scala:79) 2022-04-22T15:09:07.396969 [APP/PROC/WEB/0] Timeout waiting for connection from pool 2022-04-22T15:09:07.397080 [APP/PROC/WEB/0] at BulkInventorySearch.IVK_GetBulkPricing (SubMicroflow : 'SUB_InvokeBulkSearchAPI') 2022-04-22T15:09:07.397173 [APP/PROC/WEB/0] at com.mendix.integration.actions.microflow.RestCallAction.execute(RestCallAction.scala:79) 2022-04-22T15:09:07.397783 [APP/PROC/WEB/0] Caused by: com.mendix.systemwideinterfaces.MendixRuntimeException: java.security.PrivilegedActionException: org.apache.http.conn.ConnectionPoolTimeoutException: Timeout waiting for connection from pool
and that appears to have helped, we may not know until there is increased load on our system next week.
Performance issues like this are always a balancing act. Updating these setting will buy you extra room to breathe.
It may also be useful to go over the microflows that cause heavy load, to check if they are as efficient as possible. Are they doing only essential stuff? Can some of it be handled asynchronously using queues for example? Is the dataset becoming to big and can it be split into an active set and an archived set using an extra boolean or an extra entity?