Spring 2.5 Perfomance Improvements 200% 直逼 Guice
来源:互联网 发布:mac cad哪个版本好用 编辑:程序博客网 时间:2024/06/05 23:47
并发性能提升的原因之一是使用了 ConcurrentHashMap,原来的 Collections.synchronized(new HashMap()) 存在同步锁的性能瓶颈;
如果你是用JDK 5.0或以上的版本,就可以直接得到这个性能的提升的好处了。
或者下载 Emory concurrent utilities backport 加到 CLASSPATH 中
http://dcl.mathcs.emory.edu/util/backport-util-concurrent/
当然还要努力,越快越好啦。。。
引用
The upcoming Spring Framework version 2.5 will bring a 200% improvement for concurrent access over Spring 2.0.*. I used Crazy Bob's Semi Useless Benchmark ™ as a starting point. I fiddled with the code slightly to change the default behavior from "prototype" to "singleton", and I saw that spring 2.5 was faster than Guice for singletons.
Here are some benchmarks (there is variability based on the runs)
* Spring 2.0 vs. guice 1.0:
o Prototype: Single thread: Spring is 50-150X slower. Concurrent: Spring is 50-150X slower.
o Singleton: Single thread: Spring 3X slower - 2X faster. Concurrent: Spring is 5-10X slower
* Spring 2.0.6 vs. guice 1.0:
o Prototype: Single thread: Spring is ~10X slower. Concurrent: Spring is 5X slower.
o Singleton: Single thread: Spring 2X slower - 2X faster. Concurrent: Spring:Guice ~2:3
* Spring 2.14m vs. guice 1.0:
o Prototype: Single thread: Spring is 5-7X slower. Concurrent: Spring is 3-4X slower.
o Singleton: Single thread: neck and neck. Concurrent: Spring is 1-1.5X faster
* guice 1.0:
o Prototype: Single thread vs. Concurrent: Concurrent might be a bit slower than single threaded
o Singleton: Single thread vs. Concurrent: Concurrent is quite a bit faster than single threaded
详细请见这里
http://www.jroller.com/Solomon/entry/spring_2_5_perfomance_improvements
如果你是用JDK 5.0或以上的版本,就可以直接得到这个性能的提升的好处了。
或者下载 Emory concurrent utilities backport 加到 CLASSPATH 中
http://dcl.mathcs.emory.edu/util/backport-util-concurrent/
当然还要努力,越快越好啦。。。
引用
The upcoming Spring Framework version 2.5 will bring a 200% improvement for concurrent access over Spring 2.0.*. I used Crazy Bob's Semi Useless Benchmark ™ as a starting point. I fiddled with the code slightly to change the default behavior from "prototype" to "singleton", and I saw that spring 2.5 was faster than Guice for singletons.
Here are some benchmarks (there is variability based on the runs)
* Spring 2.0 vs. guice 1.0:
o Prototype: Single thread: Spring is 50-150X slower. Concurrent: Spring is 50-150X slower.
o Singleton: Single thread: Spring 3X slower - 2X faster. Concurrent: Spring is 5-10X slower
* Spring 2.0.6 vs. guice 1.0:
o Prototype: Single thread: Spring is ~10X slower. Concurrent: Spring is 5X slower.
o Singleton: Single thread: Spring 2X slower - 2X faster. Concurrent: Spring:Guice ~2:3
* Spring 2.14m vs. guice 1.0:
o Prototype: Single thread: Spring is 5-7X slower. Concurrent: Spring is 3-4X slower.
o Singleton: Single thread: neck and neck. Concurrent: Spring is 1-1.5X faster
* guice 1.0:
o Prototype: Single thread vs. Concurrent: Concurrent might be a bit slower than single threaded
o Singleton: Single thread vs. Concurrent: Concurrent is quite a bit faster than single threaded
详细请见这里
http://www.jroller.com/Solomon/entry/spring_2_5_perfomance_improvements
- Spring 2.5 Perfomance Improvements 200% 直逼 Guice
- Spring 2.5 Perfomance Improvements 200% 直逼 Guice
- Spring 2.5 Perfomance Improvements 200% 直逼 Guice
- Spring 2.5 Perfomance Improvements 200% 直逼 Guice
- Spring 2.5 Perfomance Improvements 200% 直逼 Guice
- Spring 2.5 Perfomance Improvements 200% 直逼 Guice
- Spring 2.5 Perfomance Improvements 200% 直逼 Guice
- Spring 2.5 Perfomance Improvements 200% 直逼 Guice
- Spring 2.5 Perfomance Improvements 200% 直逼 Guice
- Spring 2.5 Perfomance Improvements 200% 直逼 Guice
- Spring 2.5 Perfomance Improvements 200% 直逼 Guice
- Spring 2.5 Perfomance Improvements 200% 直逼 Guice
- Spring 2.5 Perfomance Improvements 200% 直逼 Guice
- Spring 2.5 Perfomance Improvements 200% 直逼 Guice
- Spring 2.5 Perfomance Improvements 200% 直逼 Guice
- Spring 2.5 Perfomance Improvements 200% 直逼 Guice
- Spring 2.5 Perfomance Improvements 200% 直逼 Guice
- Spring 2.5 Perfomance Improvements 200% 直逼 Guice
- 产生 java.lang.NoClassDefFoundError 的另一种意外情况:jar包部分的物理性损坏
- Windows API一日一练(54)WriteFile和ReadFile函数
- Windows API一日一练(46)EnterCriticalSection和LeaveCriticalSection函数
- 通用分页控件(DataGrid,DataList,Repeater都可以用它来分页)
- 如何获得数据库里所有表的名字(SQL+C#)
- Spring 2.5 Perfomance Improvements 200% 直逼 Guice
- Windows API一日一练(53)CreateFile函数
- 海量数据处理分析
- J2ME程序开发新手入门要领
- Apache CXF 在 WebLogic 9.2 上的问题定位分析及权宜之计
- Windows API一日一练(52)GetCurrentDirectory和SetCurrentDirectory函数
- Windows API一日一练(45)CreateEvent和SetEvent函数
- 《多任务下的数据结构与算法》一书的勘误
- JavaEE事务扫盲笔记之一扫扫到尾