不同版本的jboss的消息配置

Case 1: HornetQ (JBoss 6)

HornetQ configuration is located in JBoss 6 in deploy\hornetq.sar. You can add new Topic/Queues by adding them into hornetq-jms.xml file.

1. < queue name = "testQueue" >
2. < entry name = "/queue/queueA" />
3. </ queue >
4.
5. < topic name = "testTopic" >
6. < entry name = "/topic/topicA" />
7. </ topic >


Case 2: JBoss Messaging (JBoss 5)
If you are running JBoss 5, which ships with JBoss messaging you can add the following XML (-service.xml ) to your deploy folder:

01. < mbean code = "org.jboss.jms.server.destination.QueueService"
02. name = "jboss.messaging.destination:service=Queue,name=queueA"
03. xmbean-dd = "xmdesc/Queue-xmbean.xml" >
04. < depends optional-attribute-name = "ServerPeer" >jboss.messaging:service=ServerPeer</ depends >
05. < depends >jboss.messaging:service=PostOffice</ depends >
06. </ mbean >
07.
08. < mbean code = "org.jboss.jms.server.destination.TopicService"
09. name = "jboss.messaging.destination:service=Topic,name=topicA"
10. xmbean-dd = "xmdesc/Topic-xmbean.xml" >
11. < depends optional-attribute-name = "ServerPeer" >jboss.messaging:service=ServerPeer</ depends >
12. < depends >jboss.messaging:service=PostOffice</ depends >
13. </ mbean >


Case 2: JBoss MQ (JBoss 4)
If you using JBoss older JMS provider, you can add the following XML (-service.xml ) to your deploy folder:

01. < mbean code = "org.jboss.mq.server.jmx.Queue"
02. name = "jboss.mq.destination:service=Queue,name=queueA" >
03. < depends optional-attribute-name = "DestinationManager" >jboss.mq:service=DestinationManager</ depends >
04. </ mbean >
05.
06. < mbean code = "org.jboss.mq.server.jmx.Topic"
07. name = "jboss.mq.destination:service=Queue,name=topicA" >
08. < depends optional-attribute-name = "DestinationManager" >jboss.mq:service=DestinationManager</ depends >
09. </ mbean >


原帖链接:http://www.mastertheboss.com/jboss-application-server/287-jboss-jms.html

你可能感兴趣的:(jboss)