Please find the Git issue in [1]. The reason behind this issue is that, When the countUsers method gets called,[2] it creates a new data source each time, when getting a connection.[3] Because of this, there will be minIdle number connections that will be left in sleep mode whenever countUsers method gets called. This is also valid for other methods in this class. (countRoles, countClaim) .This leads to connection pool exhaustion if we load the list user/role page several times.
And to solve this issue I have implemented the count logic in the carbon-kernel as in the PR [4]. By this implementation, we can count the users and roles that in the JDBC userstore and because of the known limitation in the LDAP we are not implementing this in the LDAP userstore (@Sarubi Thillainathan <[email protected]> has researched on this) . As you can see in [4] I have done the backend implementation and the fixing admin service according to this is in-progress. I will update the thread after the process is done. [1] . https://github.com/wso2/product-is/issues/4306 [2] . https://github.com/wso2/carbon-identity-framework/blob/master/components/user-store/org.wso2.carbon.identity.user.store.count/src/main/java/org/wso2/carbon/identity/user/store/count/jdbc/JDBCUserStoreCountRetriever.java#L58 [3]. https://github.com/wso2/carbon-identity-framework/blob/master/components/user-store/org.wso2.carbon.identity.user.store.count/src/main/java/org/wso2/carbon/identity/user/store/count/jdbc/JDBCUserStoreCountRetriever.java#L185 [4]. https://github.com/wso2/carbon-kernel/pull/2350 Thanks wijith -- Wijith Bandara Software Engineer | WSO2 Email : [email protected] Mobile : +94718970370 Web : http://wso2.com <http://wso2.com/signature>
_______________________________________________ Architecture mailing list [email protected] https://mail.wso2.org/cgi-bin/mailman/listinfo/architecture
