|
RSS Feed - WebSphere MQ Support
|
RSS Feed - Message Broker Support
|
 |
|
Programming mq with base JAVA MQI(MQ API) |
« View previous topic :: View next topic » |
Author |
Message
|
jeevan |
Posted: Wed Aug 19, 2009 1:21 pm Post subject: Programming mq with base JAVA MQI(MQ API) |
|
|
Grand Master
Joined: 12 Nov 2005 Posts: 1432
|
I am a MQ administrator not a programmer. But started looking into basic programming. I know there are 13 main apis/calls and there are a few minor calls. However, when I looked at one of the free sample mq java apps, I could not see some standrdad eg MQOPEN or MQCLOSE call made but the app works perfectly
I am not asking how to programme but just a broad framework mq programming using java. I will definitely read the redbook.
Eg. instead of mqopen I saw this to connect to queue manager and browse the queue.
browseQueue = qMgr.accessQueue(myQueue, openOptions, null, null, null);
Even I did not find MQCONNECT however, I find the disconnect eg
qMgr.disconnect();
Could you please some one shed some light on it?
thanks |
|
Back to top |
|
 |
Vitor |
Posted: Wed Aug 19, 2009 1:55 pm Post subject: Re: Programming mq with base JAVA MQI(MQ API) |
|
|
 Grand High Poobah
Joined: 11 Nov 2005 Posts: 26093 Location: Texas, USA
|
jeevan wrote: |
Could you please some one shed some light on it? |
Java doesn't use the MQI calls like other languages. You can use similar native calls but more typically Java uses JMS to manipulate queues and messages.
Because Java is object orientated the queue manager, queues and messages are all objects. Hence (in the example you quote) you first instansiate a queue manager object (part of which describes the connection parameters) and use a method of the queue manager object to create a queue object (part of which includes the open options).
The Using Java manual, and most of the standard Java texts, will tell you all you need to know and much better than I can. _________________ Honesty is the best policy.
Insanity is the best defence. |
|
Back to top |
|
 |
jeevan |
Posted: Wed Aug 19, 2009 2:19 pm Post subject: Re: Programming mq with base JAVA MQI(MQ API) |
|
|
Grand Master
Joined: 12 Nov 2005 Posts: 1432
|
Vitor wrote: |
jeevan wrote: |
Could you please some one shed some light on it? |
Java doesn't use the MQI calls like other languages. You can use similar native calls but more typically Java uses JMS to manipulate queues and messages.
Because Java is object orientated the queue manager, queues and messages are all objects. Hence (in the example you quote) you first instansiate a queue manager object (part of which describes the connection parameters) and use a method of the queue manager object to create a queue object (part of which includes the open options).
The Using Java manual, and most of the standard Java texts, will tell you all you need to know and much better than I can. |
Thanks for the reply.
Are you saying, these API calls are for non object oriented language. but java has an object and methods so does not make exactly these calls. But some of the method may look similar eg qmgr.disconnect()
Last edited by jeevan on Wed Aug 19, 2009 2:21 pm; edited 2 times in total |
|
Back to top |
|
 |
Vitor |
Posted: Wed Aug 19, 2009 2:21 pm Post subject: Re: Programming mq with base JAVA MQI(MQ API) |
|
|
 Grand High Poobah
Joined: 11 Nov 2005 Posts: 26093 Location: Texas, USA
|
jeevan wrote: |
Are you saying, these API calls are for non object oriented language. but java has an object and methods so does not make exactly these calls. But some of the method may look similar eg qmgr.disconnect() |
 _________________ Honesty is the best policy.
Insanity is the best defence. |
|
Back to top |
|
 |
|
|
 |
|
Page 1 of 1 |
|
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
|
|
|
|