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 API Support » MQGET API call with Mercury Loadrunner and MQTester fails

Post new topic  Reply to topic
 MQGET API call with Mercury Loadrunner and MQTester fails « View previous topic :: View next topic » 
Author Message
4integration
PostPosted: Fri Sep 28, 2007 1:24 am    Post subject: MQGET API call with Mercury Loadrunner and MQTester fails Reply with quote

Disciple

Joined: 04 Sep 2006
Posts: 197
Location: Gothenburg, Sweden

Hello,

I am a newbie in using MQ API directly since we are normally using WMB. I am trying to get messages from MQ using LoadRunner and MQTester.

The error I get is:
Code:
lrmq_connect - MQCONN Completed Successfully
lrmq_open - MQOPEN Completed Successfully
vuser_init.c(45): Error: lrmq_get_message - MQGET FAILED:  CompCode [2], Reason Code [2037]
lrmq_commit - MQCMIT Completed Successfully
lrmq_close - MQCLOSE Completed Successfully
lrmq_disconnect - MQDISC Completed Successfully


Can it be a problem with the connection opening?
Any guidance would be appreicated.

The LoadRunner script:
Code:
//
//   Vuser Initialization Function
//
//   Test script for MQPUT
//
#include "lrmq.h"


int vuser_init ()
{

   /**/
   char QMGR_HANDLE[]    = "MQHCONN_MQMGR_HANDLE";

   //char QMGR_NAME[]    = "WBRK6_DEFAULT_QUEUE_MANAGER";
   char QMGR_NAME[]    = "EOWYN_B3";
   char OBJECT_HANDLE[]   = "MQHOBJ_LOADRUNNER.TEST";
   char QUEUE_NAME[]      = "PLSCM.MDM.ERROR";

   char TEMP[60000];

   lrmq_initialize ();
   lrmq_connect (
      QMGR_HANDLE,
      QMGR_NAME);

   lrmq_open (
      QMGR_HANDLE,
      OBJECT_HANDLE,
      "LRMQ_MQOO_START",
      "MQOO_BROWSE",
      "MQOO_OUTPUT",
      "MQOO_FAIL_IF_QUIESCING",
      "LRMQ_MQOO_END",
      "LRMQ_MQOD_START",
         // Queue name (using a existing queue in the test)
         "ObjectName=PLSCM.MDM.ERROR",   
         "AlternateSecurityId=1424496",
      "LRMQ_MQOD_END",
      "LRMQ_LAST_ARG"
      );

   //lrmq_set_get_message_size(256);

    lrmq_get_message (
      QMGR_HANDLE,
      OBJECT_HANDLE,
      TEMP,
      //"MESSAGE_001",
      "LRMQ_MQMD_START",
      "LRMQ_MQMD_END",
      "LRMQ_MQGMO_START",
         "Version=2",
         "Options=MQGMO_WAIT",
         "Options=MQGMO_CONVERT",
         "Options=MQGMO_ACCEPT_TRUNCATED_MSG",
         "WaitInterval=15000",
         "MsgToken=\x15c730",
      "LRMQ_MQGMO_END",
      "LRMQ_LAST_ARG"
      );

    lrmq_commit (QMGR_HANDLE);

   lrmq_close (
      QMGR_HANDLE,
      OBJECT_HANDLE,
      "MQCO_NONE"
      );

    lrmq_disconnect (QMGR_HANDLE);

   return (LR_PASS);
}


_________________
Best regards
4 Integration
Back to top
View user's profile Send private message
Vitor
PostPosted: Fri Sep 28, 2007 1:57 am    Post subject: Reply with quote

Grand High Poobah

Joined: 11 Nov 2005
Posts: 26093
Location: Texas, USA

Reason code 2037 is "Not open for input".

Your problem would appear to be specifying MQOO_OUTPUT and then trying to get messages.[/code]
_________________
Honesty is the best policy.
Insanity is the best defence.
Back to top
View user's profile Send private message
4integration
PostPosted: Fri Sep 28, 2007 2:19 am    Post subject: Reply with quote

Disciple

Joined: 04 Sep 2006
Posts: 197
Location: Gothenburg, Sweden

Yes, that's correct changing from MQOO_OUTPUT to MQOO_INPUT_SHARED seems to solve it.

Now I only have to verify the data that are gotten (not a LoadRunner expert )
Thanks!
_________________
Best regards
4 Integration
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 API Support » MQGET API call with Mercury Loadrunner and MQTester fails
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.