Ehcache Server provides a RESTful API for cache operations. I am working on v0.9 and have been doing some performance benchmarks. I thought it would be interesting to compare it with the performance of that other over-the-network cache, Memcache. Now I already knew that Ehcache in-process was around 1,000 times faster than Memcache. But what would the over-the-network comparison be. Here are the results:Memcache and SpyMemcache Client10000 sets: 3396ms10000 gets: 3551ms10000 getMulti: 2132ms10000 deletes: 2065msEhcache 0.9 with Ehcache 2.0.0 10000 puts: 2961ms10000 gets: 3841ms10000 deletes: 2685msSo, the results are a wash. Memcache is slightly slower on put, maybe because the JVM does not have to malloc, it already has the memory in heap. And very slightly faster on get and delete. A few years ago there was a raging thread on the Memcache mailing list about Memcache versus MySQL with in-memory tables. They were also a wash. I think the point is that serialization and network time is more significant than the server time, provided the server is not that much different. Read more: Greg Luck's Blog
0 comments:
Post a Comment