如果我使用config \ stand-alone \ non-clustered配置文件运行HornetQ,HornetQ服务器启动正常。
如果我从hornetq-beans.xml文件中删除JNDI和JMS部分:
<!-- JNDI server. Disable this if you don't want JNDI -->
<bean name="JNDIServer" class="org.jnp.server.Main">
<property name="namingInfo">
<inject bean="Naming"/>
</property>
<property name="port">1099</property>
<property name="bindAddress">localhost</property>
<property name="rmiPort">1098</property>
<property name="rmiBindAddress">localhost</property>
</bean>
和
<!-- The JMS server -->
<bean name="JMSServerManager" class="org.hornetq.jms.server.impl.JMSServerManagerImpl">
<constructor>
<parameter>
<inject bean="HornetQServer"/>
</parameter>
</constructor>
</bean>
我让服务器立即死亡。这是我得到的输出:
C:\development\hornetQ\hornetq-2.2.14.Final\bin>run.bat ..\config\custom
A subdirectory or file ..\logs already exists.
***********************************************************************************
"java -XX:+UseParallelGC -XX:+AggressiveOpts -XX:+UseFastAccessorMethods -Xms512M - Xmx1024M -Dhornetq.config.dir=..\config\custom
-Djava.util.logging.config.file=..\config\custom\logging.properties -java.library.path=. -classpath ..\config\custom;..\schemas\;
C:\development\hornetQ\hornetq-2.2.14.Final\lib\hornetq-bootstrap.jar;C:\development\hornetQ\hornetq-2.2.14.Final\lib\hornetq-core-client-java5.jar;
C:\development\hornetQ\hornetq-2.2.14.Final\lib\hornetq-core-client.jar;C:\development\hornetQ\hornetq-2.2.14.Final\lib\hornetq-core.jar;
...等
***********************************************************************************
* [main] 28-Aug 11:7:22,132 INFO [HornetQBootstrapServer] Starting HornetQ Server
* [main] 28-Aug 11:7:23,91 WARNING [FileConfigurationParser] AIO wasn't located on this platform, it will fall back to using pure Java NIO. If your platform is Linux, install
LibAIO to enable the AIO journal
* [hornetq-shutdown-thread] 28-Aug 11:7:23,147 INFO [HornetQBootstrapServer] Stopping HornetQ Server...
如果有人告诉我我做错了什么,我将不胜感激。