Author |
Message
|
maxis |
Posted: Fri Aug 04, 2006 12:58 am Post subject: c# and mq cluster |
|
|
Centurion
Joined: 25 Jun 2002 Posts: 144
|
Hi ..
In java/jms when we write and read a message from clustered queue we dont give queue manager name. How do i replicate the same thing in C#.
Task is to read and write from clustered queue from C# application. If someone is having code snippet will you please share it ....
thanks
M |
|
Back to top |
|
 |
jefflowrey |
Posted: Fri Aug 04, 2006 1:31 am Post subject: |
|
|
Grand Poobah
Joined: 16 Oct 2002 Posts: 19981
|
The only way to avoid specifying a queue manager name is by using a client connection - which uniquely identifies a particular queue manager by hostname/address, channel name and port number.
So take the client sample for C#.
Or are you looking for something like a JNDI equivalent for C#? _________________ I am *not* the model of the modern major general. |
|
Back to top |
|
 |
maxis |
Posted: Fri Aug 04, 2006 1:45 am Post subject: |
|
|
Centurion
Joined: 25 Jun 2002 Posts: 144
|
when I pass '' - null, parameter to the following piece of code
oMQQueueManager = New MQQueueManager(sMQQueueManager, ConnProperties)
oMQQueue = oMQQueueManager.AccessQueue(sMQQueue, openOptions)
its throwing an error when I try to create the Queue object. Is there an alternate way to create the queue object ? or to pass the queue manager name as null ?.
Remember .. task is to write/read from a clustered queue ..
M |
|
Back to top |
|
 |
jefflowrey |
Posted: Fri Aug 04, 2006 1:49 am Post subject: |
|
|
Grand Poobah
Joined: 16 Oct 2002 Posts: 19981
|
Remember - there's nothing special about a clustered queue, except you can PUT to it from many places without additional administration work.
As to passing in Null...
don't do that.
Pass in "" instead. _________________ I am *not* the model of the modern major general. |
|
Back to top |
|
 |
chinna |
Posted: Fri Aug 18, 2006 12:27 am Post subject: clustered queue connection in C# |
|
|
Newbie
Joined: 27 May 2005 Posts: 8
|
Please try using the open option for the queue while using AccessQueue funtion in C# to connect to clustered queue.
AccessQueue(queueName, MQC.MQOO_INPUT_AS_Q_DEF + MQC.MQOO_FAIL_IF_QUIESCING);
I hope it will work.
Thanks
Chinna |
|
Back to top |
|
 |
|