我已经在ubuntu上安装了libaio,并且运行了HornetQ embedded,通过编程配置,我这样做是为了在日志上使用AIO,但是我看到在启动时,它没有获得AIO,总是使用NIO。有办法确定它为什么会失败吗?
Configuration configuration = new ConfigurationImpl();
boolean supportsAIO = AIOSequentialFileFactory.isSupported();
if (supportsAIO) {
configuration.setJournalType(JournalType.ASYNCIO);
log.info("** using AIO **");
} else {
configuration.setJournalType(JournalType.NIO);
log.info("** using NIO **");
}发布于 2014-03-20 13:06:08
您必须定义-Djava.library.path=PathToYourBinaries
您应该在PathToYourBinaries拥有以下文件:
如果您仍然无法加载它,那么就需要重新编译系统中的本地程序,但是很可能您只需要定义java.library.path。
https://stackoverflow.com/questions/22523573
复制相似问题