Question about RiakCluster - Java client - 2.x

Konstantin Kalin konstantin.kalin at
Mon Nov 21 15:49:18 EST 2016

I'm currently migrating Java client from 1.4 to 2.1 and I have a question
about RiakCluster class.

We hide Riak Java API by our interface since we use multiple backends and
Riak is one of them.
Let's say I have two independent business activities that makes calls to
Riak cluster. Both activities are executed within same Tomcat instance.
Currently we use two RiakClient instances (1.4). Each activity initializes
its own RiakClient.
Since I do the migration I cannot decide. Would it have more sense to
create a "singleton" object that will own RiakCluster instead of creating
two instances? What should I consider as recommended approach?

Thank you,
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <>

More information about the riak-users mailing list