golang consistent hash 菜鸟分析
一直找集群的算法,刚好golang上面有一个适合。下面作为菜鸟来分析一下 // Copyright (C) 2012 Numerotron Inc. // Use of this source code is governed by an MIT-style license // that can be found in the LICENSE file. // Package consistent provides a consistent hashing function. // // Consistent hashing is often used to distribute requests to a changing set of servers. For example, // ...阅读全文