Java HTTP Client running out of FD's
russell.brown at mac.com
Fri Feb 25 05:12:21 EST 2011
On Fri, 2011-02-25 at 09:58 +0530, Abhishek Kona wrote:
> Also I am not clear about the RiakClient's thread safety. If I share
> the RiakClient should the client code maintain locks on it.
Well technically no, it is not strictly thread safe (it retains a
reference to the mutable RiakConfig it is constructed with, for
example.) You can use it safely across threads *if* you safely publish
it and then treat it as _effectively immutable_. Then you can leverage
the single HttpClient with the MultiThreadedConnectionManager.
It will be thread safe in the near future.
More information about the riak-users