ActiveMQ入门

当前最新的ActiveMQ版本为5.13.0

下载地址http://activemq.apache.org/download.html

下载得到apache-activemq-5.13.0-bin.zip文件(win),或apache-activemq-5.13.0-bin.tar.gz文件(linux)

以windows 64位环境为例

解压,进入bin/win64,点击运行activemq.bat,成功后会显示如下内容

jvm 1    |  INFO | Connector ws started

jvm 1    |  INFO | Apache ActiveMQ 5.13.0 (localhost, ID:PC-WS-3049-1453431870826-0:1) started

jvm 1    |  INFO | For help or more information please see: http://activemq.apache.org

jvm 1    |  INFO | No Spring WebApplicationInitializer types detected on classpath

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/api/jolokia/

jvm 1    |  INFO | Initializing Spring FrameworkServlet 'dispatcher'

jvm 1    |  INFO | No Spring WebApplicationInitializer types detected on classpath

jvm 1    |  INFO | jolokia-agent: No access restrictor found at classpath:/jolokia-access.xml, access to all MBeans is allowed

在浏览器中访问http://127.0.0.1:8161/admin/,测试是否启动成功(默认用户名密码admin:admin)


用eclipse(安装有maven插件m2e)导入examples\openwire\java目录中的java例子工程

分别执行Listener.main和Publisher.main测试java客户端

测试java连接MQ的代码


停止MQ, ctrl+C


你可能感兴趣的:(java,部署,activemq,客户端)