Hi, I'm trying to ensure that my own code is handling HttpEntities and their streams properly, so that the underlying connections get returned to the pool.
Is there a recommended way to write unit tests for this? It seems I'll have to check connManager.pool.leasedConnections.size() == 0 after each operation, but since they're protected members I have to subclass both the connection manager and connection pool classes to get the value out. Is there better approach? Also, is there away to glean from a leased connection pool entry what URL it was used to fetch? (The entire URL, not just the 'route') That would be helpful with troubleshooting any issues that weren't caught by the unit testing. Thanks, John --------------------------------------------------------------------- To unsubscribe, e-mail: [email protected] For additional commands, e-mail: [email protected]
