implemented basic consistent hashing