Java 高性能IO

来源:互联网 发布:java 嵌套循环 编辑:程序博客网 时间:2024/06/09 14:17

今天看到theserverside上的一篇文章介绍JBoss的HornetQ,说是其性能大大优于ActiveMQ等其他mom,很好奇,看了一下,发现差距最大的地方在使用persistent mode的情况下。看网上介绍,说是使用了Linux Asynchronous IO (AIO),才得以获得更棒的性能。说是ActiveMQ6中也准备引入该机制。

 

Linux 2.5的Asynchronous I/O分析---wheelz

http://www.linuxforum.net/forum/gshowflat.php?Cat=&Board=linuxK&Number=497055&page=8&view=expanded&sb=5&o=all

 

以前一直用的是java nio,也没有做过什么对io性能要求特别高的项目,就顺带了解了一下以下一些高性能的java io实现:

http://mina.apache.org/


Grizzly

. This is the I/O core for Sun's GlassFish server. Grizzly provides a facility for doing asynchronous reads/writes (via a queue model). It supports TCP and UDP a like. I've used Grizzly in a couple of projects. There are things I like and dislike about the framework, but to detail this is really another topic. I will say that it's quite easy to get something up and running and Grizzly does a lot of the heavy lifting for you.

  • Netty. This project comes from one of the original authors on the Mina project. I haven't used this one so I don't know about about its support for asynchronous I/O. You should take a look.
  • 原创粉丝点击