Topic
  • 1 reply
  • Latest Post - ‏2005-07-13T13:29:03Z by SystemAdmin
SystemAdmin
SystemAdmin
684 Posts

Pinned topic Using MQeMQMsgObject

‏2005-07-11T22:27:00Z |
Hi All,

I am trying to send a simple message to an WS MQ Queue Manager via an MQe
Gateway.

I have setup the Bridge, proxy, client connection and bridge queue on the
MQe Gateway. On the MQe Client, I have setup an indirect connection via the
gateway MQe QManager, and a sync. proxy queue to the bridge queue on the MQe
Gateway.

I am able to send MQeMQMsgObject's to the WS MQ QueueManager from the MQe
Client using MQe_Explorer. I am also able to send MQeMsgObject's to the WS
MQ QueueManger programmatically (by modifying the
examples.application.Example1). The problem with that is the message that I
receive on the MQ Queue contains some extra data before the actual message.

So, I figure that I should be using the MQeMQMsgObject. However, when I
send the MQeMQMsgObject (using the same code and configuration), I get the
following message:

Example1 Failed! com.ibm.mqe.MQeException: com.ibm.mqe.MQeException: Queue
Manager not setExample1QM 75 (code=12) on clientQMclientQM 4 (code=600)
com.ibm.mqe.MQeException: com.ibm.mqe.MQeException: Queue Manager not
setExample1QM 75 (code=12) on clientQMclientQM 4 (code=600)
at com.ibm.mqe.MQeTransporter.putMessage(DashoA8173)
at com.ibm.mqe.MQeRemoteQueue._synchronousPutMessage(DashoA8173)
at com.ibm.mqe.MQeRemoteQueue.putMessage(DashoA8173)
at com.ibm.mqe.MQeQueueManager.internalPutMessage(DashoA8173)
at com.ibm.mqe.MQeQueueManager.putMessage(DashoA8173)
at examples.application.Example1.doIt(Example1.java:106)
at examples.application.Example1.main(Example1.java:159)
Example failed: com.ibm.mqe.MQeException: com.ibm.mqe.MQeException: Queue
Manager not setExample1QM 75 (code=12) on clientQMclientQM 4 (code=600)
My code is as follows:
MQeMsgObject msgObj1 = new MQeMsgObject();
queueName = "BRIDGEQ";

msgObj1.putArrayOfByte("",byteMsg);
MQeMQMsgObject msgObj2 = new MQeMQMsgObject(msgObj1);
/*
* Put msg to queue
*/
System.out.println("..Put the message tod QM/queue: " + qMgrName
+ "/" + queueName);
myQM.putMessage(qMgrName, queueName, msgObj2, null, 0);

Am I missing a configuration step? Should I be using the MQeMQMsgObject?
Any help would be appreciated.

Thanks in advance,
Rahim
Updated on 2005-07-13T13:29:03Z at 2005-07-13T13:29:03Z by SystemAdmin
  • SystemAdmin
    SystemAdmin
    684 Posts

    Re: Using MQeMQMsgObject

    ‏2005-07-13T13:29:03Z  
    Hi,

    Try using MQeMQMsgObject as follows and see

    MQeMQMsgObject obj=new MQeMQMsgObject ();
    queueName="BRIDGEQ";
    obj.setData(msgData.getBytes());
    myQM.putMessage(qMgrName, queueName, obj, null, 0);
    regards,
    Vijay
    "Rahim Lalani" <rahim_lalani@hotmail.com> wrote in message
    news:daurnp$4crm$1@news.boulder.ibm.com...
    > Hi All,
    >
    > I am trying to send a simple message to an WS MQ Queue Manager via an MQe
    > Gateway.
    >
    > I have setup the Bridge, proxy, client connection and bridge queue on the
    > MQe Gateway. On the MQe Client, I have setup an indirect connection via
    the
    > gateway MQe QManager, and a sync. proxy queue to the bridge queue on the
    MQe
    > Gateway.
    >
    > I am able to send MQeMQMsgObject's to the WS MQ QueueManager from the MQe
    > Client using MQe_Explorer. I am also able to send MQeMsgObject's to the
    WS
    > MQ QueueManger programmatically (by modifying the
    > examples.application.Example1). The problem with that is the message that
    I
    > receive on the MQ Queue contains some extra data before the actual
    message.
    >
    > So, I figure that I should be using the MQeMQMsgObject. However, when I
    > send the MQeMQMsgObject (using the same code and configuration), I get the
    > following message:
    >
    > Example1 Failed! com.ibm.mqe.MQeException: com.ibm.mqe.MQeException: Queue
    > Manager not setExample1QM 75 (code=12) on clientQMclientQM 4
    (code=600)
    > com.ibm.mqe.MQeException: com.ibm.mqe.MQeException: Queue Manager not
    > setExample1QM 75 (code=12) on clientQMclientQM 4 (code=600)
    > at com.ibm.mqe.MQeTransporter.putMessage(DashoA8173)
    > at com.ibm.mqe.MQeRemoteQueue._synchronousPutMessage(DashoA8173)
    > at com.ibm.mqe.MQeRemoteQueue.putMessage(DashoA8173)
    > at com.ibm.mqe.MQeQueueManager.internalPutMessage(DashoA8173)
    > at com.ibm.mqe.MQeQueueManager.putMessage(DashoA8173)
    > at examples.application.Example1.doIt(Example1.java:106)
    > at examples.application.Example1.main(Example1.java:159)
    > Example failed: com.ibm.mqe.MQeException: com.ibm.mqe.MQeException: Queue
    > Manager not setExample1QM 75 (code=12) on clientQMclientQM 4
    (code=600)
    > My code is as follows:
    > MQeMsgObject msgObj1 = new MQeMsgObject();
    > queueName = "BRIDGEQ";
    >
    > msgObj1.putArrayOfByte("",byteMsg);
    > MQeMQMsgObject msgObj2 = new MQeMQMsgObject(msgObj1);
    > /*
    > * Put msg to queue
    > */
    > System.out.println("..Put the message tod QM/queue: " +
    qMgrName
    > + "/" + queueName);
    > myQM.putMessage(qMgrName, queueName, msgObj2, null, 0);
    >
    > Am I missing a configuration step? Should I be using the MQeMQMsgObject?
    > Any help would be appreciated.
    >
    > Thanks in advance,
    > Rahim
    >
    >
    >