公司最近会用MQ对某些业务进行处理,所以,这次我下载了apache-activemq-5.12.0-bin把玩下。
基于练习方便需要,使用Windows的版本。
参考的优秀文章:
Winsdows下安装
下载后得到zip文件,解压后用命令行启动即可使用,有两个问题需注意。
- 启动的文件根据不同的系统类型,也分为32位、64位,请选择自身系统的启动文件
- 目前的apache-activemq-5.12.0版本需要1.7的JDK运行
D:\green\apache-activemq-5.12.0\bin\win64\activemq.bat
启动后,可见如下类型的日志,即正常启动:
C:\Users\Administrator>D:\green\apache-activemq-5.12.0\bin\win64\activemq.bat wrapper | --> Wrapper Started as Console wrapper | Launching a JVM... jvm 1 | Wrapper (Version 3.2.3) http://wrapper.tanukisoftware.org jvm 1 | Copyright 1999-2006 Tanuki Software, Inc. All Rights Reserved. jvm 1 | jvm 1 | Java Runtime: Oracle Corporation 1.7.0_71 D:\green\JDK\jdk1.7.0_71\jr e7 jvm 1 | Heap sizes: current=61440k free=55845k max=932352k jvm 1 | JVM args: -Dactivemq.home=../.. -Dactivemq.base=../.. -Djavax.net .ssl.keyStorePassword=password -Djavax.net.ssl.trustStorePassword=password -Djav ax.net.ssl.keyStore=../../conf/broker.ks -Djavax.net.ssl.trustStore=../../conf/b roker.ts -Dcom.sun.management.jmxremote -Dorg.apache.activemq.UseDedicatedTaskRu nner=true -Djava.util.logging.config.file=logging.properties -Dactivemq.conf=../ ../conf -Dactivemq.data=../../data -Djava.security.auth.login.config=../../conf/ login.config -Xmx1024m -Djava.library.path=../../bin/win64 -Dwrapper.key=XfRgHYr WI1FG6qgT -Dwrapper.port=32000 -Dwrapper.jvm.port.min=31000 -Dwrapper.jvm.port.m ax=31999 -Dwrapper.pid=4536 -Dwrapper.version=3.2.3 -Dwrapper.native_library=wra pper -Dwrapper.cpu.timeout=10 -Dwrapper.jvmid=1 jvm 1 | Extensions classpath: jvm 1 | [..\..\lib,..\..\lib\camel,..\..\lib\optional,..\..\lib\web,..\..\l ib\extra] jvm 1 | ACTIVEMQ_HOME: ..\.. jvm 1 | ACTIVEMQ_BASE: ..\.. jvm 1 | ACTIVEMQ_CONF: ..\..\conf jvm 1 | ACTIVEMQ_DATA: ..\..\data jvm 1 | Loading message broker from: xbean:activemq.xml jvm 1 | INFO | Refreshing org.apache.activemq.xbean.XBeanBrokerFactory$1@3b7 94c60: startup date [Tue Aug 18 23:20:11 CST 2015]; root of context hierarchy jvm 1 | INFO | PListStore:[D:\green\apache-activemq-5.12.0\bin\win64\..\..\d ata\localhost\tmp_storage] started jvm 1 | INFO | Using Persistence Adapter: KahaDBPersistenceAdapter[D:\green\ apache-activemq-5.12.0\bin\win64\..\..\data\kahadb] jvm 1 | INFO | KahaDB is version 6 jvm 1 | INFO | Recovering from the journal @1:138575 jvm 1 | INFO | Recovery replayed 9 operations from the journal in 0.02 secon ds. jvm 1 | INFO | Apache ActiveMQ 5.12.0 (localhost, ID:USER-20141117SF-63255-1 439911212886-0:1) is starting jvm 1 | INFO | Listening for connections at: tcp://USER-20141117SF:61616?max imumConnections=1000&wireFormat.maxFrameSize=104857600 jvm 1 | INFO | Connector openwire started jvm 1 | INFO | Listening for connections at: amqp://USER-20141117SF:5672?max imumConnections=1000&wireFormat.maxFrameSize=104857600 jvm 1 | INFO | Connector amqp started jvm 1 | INFO | Listening for connections at: stomp://USER-20141117SF:61613?m aximumConnections=1000&wireFormat.maxFrameSize=104857600 jvm 1 | INFO | Connector stomp started jvm 1 | INFO | Listening for connections at: mqtt://USER-20141117SF:1883?max imumConnections=1000&wireFormat.maxFrameSize=104857600 jvm 1 | INFO | Connector mqtt started jvm 1 | {} jvm 1 | INFO | Listening for connections at ws://USER-20141117SF:61614?maxim umConnections=1000&wireFormat.maxFrameSize=104857600 jvm 1 | INFO | Connector ws started jvm 1 | INFO | Apache ActiveMQ 5.12.0 (localhost, ID:USER-20141117SF-63255-1 439911212886-0:1) started jvm 1 | INFO | For help or more information please see: http://activemq.apac he.org jvm 1 | INFO | ActiveMQ WebConsole available at http://0.0.0.0:8161/ jvm 1 | INFO | ActiveMQ Jolokia REST API available at http://0.0.0.0:8161/ap i/jolokia/ jvm 1 | INFO | Initializing Spring FrameworkServlet 'dispatcher' jvm 1 | INFO | jolokia-agent: No access restrictor found at classpath:/jolok ia-access.xml, access to all MBeans is allowed