2 Replies Latest reply on Jun 27, 2011 1:24 PM by clebert.suconic

    Why HornetQ use JNI for libaio for file I/O only

    escort

      Dear all,

       

      As you may know, HornetQ uses JNI implemention for libaio as part of journal I/O operations. The relevent information could be found in the following links

       

      http://hornetq.sourceforge.net/docs/hornetq-2.0.0.BETA5/user-manual/en/html/libaio.html

      http://hornetq.sourceforge.net/docs/hornetq-2.0.0.BETA5/user-manual/en/html/persistence.html

       

      After examing the source code, I am courious, since HornetQ has already implemented the JNI for libasio, why it does not implement the socket I/O at the same time.

       

      http://lse.sourceforge.net/io/aio.html

       

      According to most of the articles, the socket I/O from C++ is faster than Java NIO. Could any one explain the reason that HornetQ only uses JNI for File I/O but not socket I/O.

       

      Thanks a lot.


      Best regards