Re: MYSQL 8.0.18 xdev, total connections are keeps increasing
Posted by: Filipe Silva
Date: October 12, 2021 04:37PM

ClientFactory provides session pooling functionality. If you instantiate a new ClientFactory every time you want a Session then you are not leveraging the session pool at all. If this is the case, you should be better by using SessionFactory instead.

In order to leverage the session pooling from the Client instance, you must keep it across the the entire execution of your application and just close it when shutting the application down.

Closing the client has the effect of also closing all sessions it is tracking. There should be none left after calling this method. Are you sure the connections you see are coming from here? Can you provide more details?

Options: ReplyQuote




Sorry, you can't reply to this topic. It has been closed.

Content reproduced on this site is the property of the respective copyright holders. It is not reviewed in advance by Oracle and does not necessarily represent the opinion of Oracle or any other party.