[infinispan-dev] CHM or CHMv8?

Mircea Markus mmarkus at redhat.com
Thu Apr 25 08:58:30 EDT 2013


On 25 Apr 2013, at 12:49, Dan Berindei wrote:

> Yeah, I don't think you could extract the hash from the "cache of hashes" without computing the hash in the first place...
> 
> My idea was to wrap the key in a KeyWithHash object and cache the hash there (since we're looking up the same key in a lot of maps during a single invocation).
My understanding of the problem Sanne tried to solve is the calculation of the hash of a key several times, in multiple interceptors, during a single operation/transaction. I don't think we should take it as far as keeping the hash together with the key. Also this is an optimisation so we shouldn't go out of our way in order to implement it.
> Sorry Galder, I forgot about your patch, but I still think we'd need a wrapper for keys in order to cache the hash code even if we could define an Equivalence function.


Cheers,
-- 
Mircea Markus
Infinispan lead (www.infinispan.org)







More information about the infinispan-dev mailing list