[jboss-user] [JCA] - Using JMS managed connections for outbound connectivity?

henk de boer do-not-reply at jboss.com
Fri Jun 25 17:47:46 EDT 2010


henk de boer [http://community.jboss.org/people/henk53] created the discussion

"Using JMS managed connections for outbound connectivity?"

To view the discussion, visit: http://community.jboss.org/message/549770#549770

--------------------------------------------------------------
If I define a JCA connection factory for JMS connections to a remote JMS provider ((JBoss Messaging), can these connections then be used for outbound connectivity? E.g. sending a message to a remote queue?

I.e. suppose I would have a definition like the one below in a -ds.xml file, with an appropriate JmsProviderAdapter for the remote JBoss AS server:


<tx-connection-factory>
    <jndi-name>RemoteJmsXA</jndi-name>
    <xa-transaction/>
    <rar-name>jms-ra.rar</rar-name>
    <connection-definition>org.jboss.resource.adapter.jms.JmsConnectionFactory</connection-definition>
    <config-property name="JmsProviderAdapterJNDI" type="java.lang.String">java:/RemoteJMSProvider</config-property>
    <max-pool-size>20</max-pool-size>       
    <depends>jboss.messaging:service=ServerPeer</depends>      
</tx-connection-factory>



What can I then do myself with these connections? Is this connection factory only supposed to be used with stuff like bridges or invokers, or can I also request a connection in user code from this factory and use it to send a JMS message to a remote queue?

I did a quick test with this, and found that no matter what I do, the messages I sent using such a managed connection always end up being handled by the local PostOffice, which has no knowledge of any remote queue or topic and thus refuses to do any routing. If I use a remote queue that happens to have the same name as a local queue, then the PostOffice seems to sent it to this local queue, even though I'm using a managed connection to the remote server and a destination that I obtained from the JNDI of the remote server.

Any insight would be highly appreciated.

--------------------------------------------------------------

Reply to this message by going to Community
[http://community.jboss.org/message/549770#549770]

Start a new discussion in JCA at Community
[http://community.jboss.org/choose-container!input.jspa?contentType=1&containerType=14&container=2098]

-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.jboss.org/pipermail/jboss-user/attachments/20100625/01837b3c/attachment-0001.html 


More information about the jboss-user mailing list