infinispan/infinispan — pull request #1327 by mgencur (2012-09-20 12:42:49+00:00)
Title: Ispn 1822 - Do not extend LinkedHashMap in LRU eviction strategy

Hi,
this is my patch that fixes https://issues.jboss.org/browse/ISPN-1822 and also one BZ for JDG.

Now the LRU eviction is not extending LinkedHashMap (which caused problems on IBM JDK) but rather HashMap.

All tests in Infinispan test suite passed for me, including EvictionWithPassivationTest and LRUEvictionFunctionalTest. They are passing on all 3 JDK variants (Oracle, IBM, OpenJDK).

I also performed a little performance test by storing 10000 entries in the case with eviction enabled and compared times on Oracle JDK with/without the patch. Results were the following (I ran the tests in that order):

1) duration: 888ms (with my patch) - this was first run - possibly the cache was not warmed up at that time
2) duration: 588ms (without the patch)
3) duration: 621ms (with my patch)
4) duration: 564ms (with my patch)
5) duration: 551ms (without the patch)

These results look quite qood to me, WDYT?

Thanks

Martin