这里会显示出您选择的修订版和当前版本之间的差别。
后一修订版 | 前一修订版 | ||
分享:技术:jms:activemq的安装 [2015/09/24 15:14] gxx 创建 |
分享:技术:jms:activemq的安装 [2015/09/24 17:07] (当前版本) gxx |
||
---|---|---|---|
行 5: | 行 5: | ||
tar zxvf apache-activemq-5.12.0-bin.tar.gz #解压文件 | tar zxvf apache-activemq-5.12.0-bin.tar.gz #解压文件 | ||
cd /home/soft/apache-activemq-5.12.0/bin/linux-x86-64 #进入目录 | cd /home/soft/apache-activemq-5.12.0/bin/linux-x86-64 #进入目录 | ||
- | ./activemq start #已daemon方式启动activemq | + | </code> |
+ | <code> | ||
+ | ./activemq start #以daemon方式启动activemq | ||
+ | ./activemq stop #关闭activemq | ||
</code> | </code> | ||
访问http://121.43.104.34:8161/admin/,用户名:admin,密码:admin,验证启动成功。 | 访问http://121.43.104.34:8161/admin/,用户名:admin,密码:admin,验证启动成功。 | ||
+ | spring整合activemq之后,启动应用,在activemq控台上会看到自动多了queue和topic,也可以看到连接的机器IP地址。 | ||
+ | |||
+ | 控台截图如下: | ||
+ | |||
+ | {{:分享:技术:jms:home.png?800|}} | ||
+ | {{:分享:技术:jms:queues.png?800|}} | ||
+ | {{:分享:技术:jms:topics.png?800|}} | ||
+ | {{:分享:技术:jms:connections.png?800|}} | ||
+ | {{:分享:技术:jms:send.png?800|}} | ||
+ | |||
+ | http://121.43.104.34:8161/admin/send.jsp 可以指定目的地,指定发送内容和发送次数。 | ||
+ | |||
+ | spring整合activemq之后的应用可以监听到消息,打出日志 | ||
+ | |||
+ | <code> | ||
+ | 2015-09-24 16:57:15,980 [jmsContainer-1] INFO [com.gxx.record.jms.ConsumerMessageListener:40] - 消息监听器接收内容:test send message | ||
+ | 2015-09-24 16:57:15,981 [jmsContainer-1] INFO [com.gxx.record.jms.ConsumerMessageListener:40] - 消息监听器接收内容:test send message | ||
+ | 2015-09-24 16:57:15,982 [jmsContainer-1] INFO [com.gxx.record.jms.ConsumerMessageListener:40] - 消息监听器接收内容:test send message | ||
+ | </code> |