twitter / twemproxy

A fast, light-weight proxy for memcached and redis
Apache License 2.0
12.13k stars 2.06k forks source link

questions about HA and key distribution #211

Open siddo420 opened 10 years ago

siddo420 commented 10 years ago

For HA, I am thinking of setting up multiple nutcracker servers (that may be used together in parallel). All nutcracker servers may be connected to the same redis+memcached servers on the backend. My questions are:

Please let me know

Thanks.

siddo420 commented 10 years ago

Also, if we want to add new redis servers to an existing pool then what happens to key distribution? Will nutcracker be querying the older servers for old data or adding new servers in an existing pool will mess up the key distribution algorithm?

vlm commented 9 years ago

The key distribution will be skewed, so some of the keys which used to connect to the older servers will be dealt with by the newer server. Moreover, depending on distribution, there can be some keys which will move from older servers to another set of the older servers.