[ldap-sdk-discuss] LDAP connection pool behaviour
A Java-based LDAP API
Brought to you by:
dirmgr,
kennethleo
From: Vladimir D. <vla...@co...> - 2016-05-11 10:53:28
|
Hi, I would like to report on some recently observed behaviour of the LDAP connection pool in v3.3.1. The setup looks like this: 8 LDAP clients, each on the node of a clustered web app. Each LDAP client is configured with an LDAP connection pool: * Initial number of connections: 0 * Max number of connections: 1024 * Max connection wait time: 500ms * Max connection age: 0 LDAP requests are run against the pool, i.e. connections are not checked out, then returned. With this setup and the typical app load the number of available connections settles to ~200. On several occasions however, when a new LDAP client / app node is started, the pool is slow to create new connections, settling to about 5 to 10, and leading to a degraded app performance. To address this, the setting for the initial number of connections was raised to 50. With this setup however, the pooled connections immediately jumped to the max limit (~1000). My question: is there any recipe or configuration strategy to ensure the pooled connection count is a good match for the LDAP request requirements of the client? We also ran a few simple tests that showed different connection build up with checked out LDAP connections, vs running requests against the pool. What is the preferred way to run LDAP requests for stable performance and optimal utilisation of the pooled connections? Any suggestions or insights will be appreciated. Thanks, Vladimir -- Vladimir Dzhuvinov |