ASG
IBM
Zystems
Cressida
Icon
Netflexity
 
  MQSeries.net
Search  Search       Tech Exchange      Education      Certifications      Library      Info Center      SupportPacs      LinkedIn  Search  Search                                                                   FAQ  FAQ   Usergroups  Usergroups
 
Register  ::  Log in Log in to check your private messages
 
RSS Feed - WebSphere MQ Support RSS Feed - Message Broker Support

MQSeries.net Forum Index » IBM MQ Java / JMS » Alternative way of putting message to a remote q

Post new topic  Reply to topic
 Alternative way of putting message to a remote q « View previous topic :: View next topic » 
Author Message
techno
PostPosted: Wed Feb 11, 2004 11:51 am    Post subject: Alternative way of putting message to a remote q Reply with quote

Chevalier

Joined: 22 Jan 2003
Posts: 429

I see this in WebSphere MQ Admin:

Code:

Using a local definition of a remote queue is not the only way of putting messages
on a remote queue. Applications can specify the full queue name, including the
remote queue manager name, as part of the MQOPEN call. In this case, you do
not need a local definition of a remote queue. However, this means that
applications must either know, or have access to, the name of the remote queue
manager at run time.


Is it somwhat equivalent to Cleint Connection in JMS? Please throw some light.

Thanks
Back to top
View user's profile Send private message
EddieA
PostPosted: Wed Feb 11, 2004 12:58 pm    Post subject: Reply with quote

Jedi

Joined: 28 Jun 2001
Posts: 2453
Location: Los Angeles

No. You can do this in Bindings Mode. All you are doing is making MQ put the message directly to the XMIT Q without a Remote Q definition.

In order to do this, MQ has to be able to resolve which XMIT Q to use based on the Queue Manager name.

Cheers,
_________________
Eddie Atherton
IBM Certified Solution Developer - WebSphere Message Broker V6.1
IBM Certified Solution Developer - WebSphere Message Broker V7.0
Back to top
View user's profile Send private message
techno
PostPosted: Wed Feb 11, 2004 4:23 pm    Post subject: Reply with quote

Chevalier

Joined: 22 Jan 2003
Posts: 429

Typical code looks like

Code:
qConnectionFactory = new MQQueueConnectionFactory();
((MQQueueConnectionFactory) qConnectionFactory).setQueueManager(sqManager);
qConnection = qConnectionFactory.createQueueConnection();
qSession = qConnection.createQueueSession(transacted, Session.AUTO_ACKNOWLEDGE);
qQueueSender = qSession.createQueue("qname");
qSender = qSession.createSender(qQueueSender);
Message msg = ...
qSender.sendMessage(msg);


Could you guide me how to do that? I don't see the place where I can give another qmgr name...

Thanks
Back to top
View user's profile Send private message
EddieA
PostPosted: Wed Feb 11, 2004 5:44 pm    Post subject: Reply with quote

Jedi

Joined: 28 Jun 2001
Posts: 2453
Location: Los Angeles

Quote:
qQueueSender = qSession.createQueue("qname");

Go look in the Java manual about URIs.

Cheers,
_________________
Eddie Atherton
IBM Certified Solution Developer - WebSphere Message Broker V6.1
IBM Certified Solution Developer - WebSphere Message Broker V7.0
Back to top
View user's profile Send private message
Display posts from previous:   
Post new topic  Reply to topic Page 1 of 1

MQSeries.net Forum Index » IBM MQ Java / JMS » Alternative way of putting message to a remote q
Jump to:  



You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
Protected by Anti-Spam ACP
 
 


Theme by Dustin Baccetti
Powered by phpBB © 2001, 2002 phpBB Group

Copyright © MQSeries.net. All rights reserved.