to answer myself if anybody else will need this too :) in the case described the right way will be not to use consistent hashing but simple modulo. If application can tolerate cache inconsistency easily - option with consistent hashing is good. In case of failure just remove failed server and most keys are unaffected. If cache consistency is somehow priority - modulo distribution is better as replacement server will take full load of failed one.
On Thursday, May 22, 2014 12:22:18 PM UTC-7, Denis Samoylov wrote: > > hi, > sorry for libmemcached question, i did not find dedicated group for it and > found question about it in this group. But if not appropriate - pls delete. > > we use chain of pecl memcached->libmemcached and use > option OPT_LIBKETAMA_COMPATIBLE. So e.g. we have three servers > "appcache1,appcache2,appcache3" and server #2 (appcache2) goes down and we > want to replace it with a new one: appcache4. Even if we feed pecl > memcached preserving order: appcache1,appcache4,appcache3 keys will not > stay with the same server :(. Is there any way to make buckets that I will > be able to assign servers and change of one server will not affect > consistent hashing? > > Thank you! > -- --- You received this message because you are subscribed to the Google Groups "memcached" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. For more options, visit https://groups.google.com/d/optout.
