The Great JCache Pull request :)

I don't think you need to worry about the size of the hashmap. The getPartitionid(key) is expensive because it involved deserialization and probably will be a lot slower than a growning hashset.