Java client API

Sean Cribbs sean at basho.com
Thu Mar 24 10:15:28 EDT 2011


On Mar 24, 2011, at 1:12 AM, Russell Brown wrote:

> 
> On 24 Mar 2011, at 06:07, Wilson MacGyver wrote:
> 
>> On Mar 23, 2011, at 2:25 PM, Jon Brisbin <jon at jbrisbin.com> wrote:
>> 
>>> I personally don't like using ambiguous short names. I get that you can technically distinguish things by package name but using a simple name that is very common isn't good for code readability. "RiakEntry" is unambiguous, self-documenting, and semantically correct. "Entry" would, in my mind, represent a very generic interface that defined various kinds of "Entry"s of things.
>>> 
>> 
>> Likewise, I'd like to suggest RiakDoc
> 
> I can see why but I think that might be too specific, not every entry in riak is a document (but every document in riak is an entry.)
> 

I understand the desire to have a better name for what you're storing in Riak (I went down that road myself in the Ruby client for a while), but for consistency's sake it makes most sense to use "object" over "entry" or "doc". Using something else just invites confusion when someone reads the wiki and other documentation and then tries to apply what they learned to a specific language driver. That said, there's no reason you can't build abstractions over the top of the object that are documents, entries, blobs, etc.

"RObject" is the class name the Ruby client uses, for what it's worth.

Sean Cribbs <sean at basho.com>
Developer Advocate
Basho Technologies, Inc.
http://basho.com/





More information about the riak-users mailing list