When I use both ways CachingClientConnectionFactory that contains FailoverClientConnectionFactory or FailoverClientConnectionFactory contains CachingClientConnectionFactory I'm getting a bottle neck in SimpleConnectionPool, because of synchronized methods in FailoverTcpConnection inner class. As findAConnection() and send(Message<?> message) are synchronized I'm getting a ConnectionPool with the only connection.
Can you explain further? I don't see a problem - see this test I just created - everything works fine, as expected.
The synchronization you talk about is at the connection level and has no impact on the pool. As you can see, I get 2 concurrent cached connections.
Bear in mind that the cache will only grow if you have concurrent work to do. If the IOs are very fast, it is difficult to get this to happen with anything except very large messages.
Kirill opened INT-3497 and commented
When I use both ways CachingClientConnectionFactory that contains FailoverClientConnectionFactory or FailoverClientConnectionFactory contains CachingClientConnectionFactory I'm getting a bottle neck in SimpleConnectionPool, because of synchronized methods in FailoverTcpConnection inner class. As findAConnection() and send(Message<?> message) are synchronized I'm getting a ConnectionPool with the only connection.
Affects: 4.0.3
Issue Links:
The text was updated successfully, but these errors were encountered: