判断hash算法好坏的四个定义
1. 平衡性(Balance):指hash的result can分布到all cache中去,use all cache can used;
2. 单调性(Monotonicity):如果已有的内容已被分配到cache中去,又有新的cache加入,确保已有 content can 映射的到new cache or already cache;
3. 分散性(Spread):分布式系统中,各终端所见的缓存区有限,且有可能不同,可能会出现相同的内容被映射到不同的cache上去,以至于降低存储效率;
4. 负载(Load):既然 same content could 映射到 same cache;so 对于特定的cache,could 会被不同的user 映射成不同的key; and the same Spread,this 情况need to avoid
参考地址:http://blog.csdn.net/cywosp/article/details/23397179/