Changing hash function

40 views
Skip to first unread message

Corey Nolet

unread,
Mar 12, 2014, 11:15:47 PM3/12/14
to couc...@googlegroups.com
I've seen a lot of posts on Google mentioning that couchbase gives the ability to change the underlying hash algorithm that is used. How would I do this? I'm using the java client.

Thanks!

Matt Ingenthron

unread,
Mar 13, 2014, 3:43:12 PM3/13/14
to couc...@googlegroups.com
Hi Corey,
Basically we have two different bucket types and each one has different options for hashing.

One is the memcached bucket.  For that, the default is ketama consistent hashing and that's what moxi will always do, but it can be overridden by client libraries.  It may also be possible to override it with moxi, but I don't recall that coming up. 

The other is the Couchbase bucket.  This has only one type of hashing.  We call it vbucket hashing, and the documentation at docs.couchbase.com covers it a bit.

If you're using a memcached bucket, you can adjust the hashing through the CouchbaseConnectionFactoryBuilder on the Java client.

Thanks,

Matt

-- 
Matt Ingenthron
Couchbase, Inc.
Reply all
Reply to author
Forward
0 new messages