码迷,mamicode.com
首页 > 其他好文 > 详细

activeMQ5官方文档翻译-运行消息中间件

时间:2015-05-31 14:10:18      阅读:252      评论:0      收藏:0      [点我收藏+]

标签:

把activeMQ中间件运行起来

注:如果你想以内嵌的方式来使用消息中间件的话你可以参照怎么在一个连接中间嵌入消息中间件 

二进制文件的方式分发的ActiveMQ自带了一个‘activemq‘的脚本文件来运行启动一个消息中间件。

 如果想了解activemq更详细的启动脚本可以回顾Unix shell脚本ActiveMQ命令行工具参考

Typing the following will run an ActiveMQ Broker using the out of the box configuration in the foreground

输入下面的命令....(后面的不知道怎么来翻译)

bin/activemq console
(译者注:在最新的5.11.1版本中要根据本机操作系统的情况进入对应的目录来才能这个命令,比如我的电脑是64位的win8,则输入以下命令:
bin/win64/activemq console

You can then use a Broker Configuration URI to specify how to start and configure your broker using a single URI. For example

你也可以使用URI配置的方式来配置启动参数,比如:

bin/activemq console broker:(tcp://localhost:61616,network:static:tcp://remotehost:61616)?persistent=false&useJmx=true

或者你也可以根据需要使用xml配置文件XBean URI的方式定制消息中间件的启动配置。比如你可以启动一个消息中间并指定对应的xml配置文件:

bin/activemq console xbean:foo.xml

Or you can use a Broker Properties URI to customize the Message Broker using a properties file; which avoids the dependency on Spring, xbean-spring and XML.

或者你也可以使用properties文件的方式以Properties URI的方式;这样也可以避免对Spring,xbean-spring以及xml的依赖。

bin/activemq console properties:foo.propertie

监控消息中间件

You can monitor ActiveMQ using the Web Console by pointing your browser at

你可以使用Web控制台来监控ActiveMQ的运行情况,你只要在浏览器中输入

http://localhost:8161/admin

注:在ActiveMQ5.8以后这个web控制台会弹出一个窗口让用户输入用户名密码。
默认的用户名密码为 admin/admin。你可以在conf/jetty-realm.properties文件中修改默认的用户名密码。

或者你也可以借助JMX支持来查看ActiveMQ的运行情况。

更多的信息请查看发行版本中的docs/WebConsole-README.txt文件。

在Servlet容器中运行消息中间件

See the source code (or WAR) of the Web Console for an example of how to run the broker inside a web application using Spring.

查看Web控制台的源代码(或WAR),它提供了一个怎么在一个web应用中使用Spring来运行消息中间件的例子。

在你的J2EE应用服务器中运行消息中间件

Whether its Apache Geronmio, JBoss, WebLogic or some other J2EE container you should be able to just reconfigure and then deploy the activemq-*.rar which is included in the binary distribution as a deployment unit in your app server. By default the rar is not configured to start an embedded broker. But by setting the brokerXmlConfig on the resource adapter configuration, the resource adapter will start an embedded broker.

For more details see J2EE

从源代码中运行消息中间件

From the latest checkout of the code you can run a broker using the ActiveMQ Performance Plugin

从Maven中运行消息中间件

(未完待续)

原文链接

Version 5 Run Broker

activeMQ5官方文档翻译-运行消息中间件

标签:

原文地址:http://my.oschina.net/u/914897/blog/422826

(0)
(0)
   
举报
评论 一句话评论(0
登录后才能评论!
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!