Test XML messages over WebSphere MQ with Rational Performance Tester: Part 1. Get started

Get an in-depth understanding of the latest feature of Java Message Server and IBM WebSphere MQ testing, which is embedded as a part of the generic service client in Rational Performance Tester software. Part 1 of this three-part tutorial explains how to record test cases for testing XML messages over the WebSphere MQ protocol Using the Rational Performance Tester generic service client.

Share:

Bharath Raj Keshavamurthy (bharathrajbk@in.ibm.com), Software performance analyst, IBM

author photoBharath works at IBM as an enterprise solutions performance lead analyst and designs solutions that meet the nonfunctional requirements of the system. He also does work pertaining to end-to-end performance engineering activities for the solution as a whole. He works with cross-brand products, with Java Virtual Machine (JVM) performance as his primary area of research and work.



23 October 2012

This section provides instructions for recording a test scenario that simulates the action of sending the test message to the system. You will record a test that puts a message into an IBM®WebSphere® MQ Input queue, gets processed by the WebSphere Message Broker, and sends the response from the Output queue, where it is picked up by IBM®Rational® Performance Tester.

Overview

The tutorial gives you a detailed understanding of the results displayed for XML message tests and how to interpret them. You can then use that information for thorough performance analysis of the system and to identify bottlenecks.

Here are the major steps that you will complete in this three-part tutorial (screen captures are included):

  1. Record a test that puts a message into a WebSphere MQ input queue to be processed by WebSphere Message Broker, with the response sent at WebSphere MQ output queue that Rational Performance Tester uses.
  2. Edit the test so that it will run with multiple data sets and validate the returned data from the message
  3. Create a test executive schedule that will run multiple iterations of the test
  4. Execute the test and examine the test log

By following these step-by-step instructions, you will get hands-on experience in creating an XML and IBM WebSphere MQ web service test. You will then enhance the test through the built-in data-driven techniques and run the test. This tutorial contains detailed steps that give you an understanding of how to doperformance testing of messaging-based applications with IBM Rational Performance Tester Extension for SOA Quality, which is a load and performance testing and problem analysis tool that extends performance and scalability testing to SOA applications.


Typical messaging solution for testing

Figure 1. Architecture diagram along with load generation environment
diagrams of architecture
Figure 2. Logical diagram and request flow
Incoming and outgoing XML messages

Description of solution and components

As you can see in the diagram in Figure 2, the solution consists of messaging components:

  • WebSphere MQ for routing and handling the messages internal to the system
  • WebSphere Message Broker for processing the message, which can include, transformation, translation and routing

This system does not have any browser using which you usually send the requests. Instead, Rational Performance Tester has a very useful utility called the generic service client, which helps in testing a system where there is no front-end or GUI. In this case, the generic service client offers an XML editor that you can use to enter the request message, configure the headers, security, add attachments, and so on. You will learn this as you progress with this tutorial

Description of application and scenarios

The application scenario consists of a message flow that accepts the incoming message intotheIN queue, processes the message, and sends it to theOUT queue. Hence, in this case, Rational Performance Tester sends a message to the IN queue and picks up the message from the OUT queue, based on correlation ID.

The sample message flow consists of three components (shown in Figure 3):

MQ Input node
This node picks up the message from the queue for processing and sends it to the next node in the flow.
 
Java Compute node
This node processes the message. The processing can be transformation, routing, calculations, and so on.
 
MQ Output node
This node directs the arriving message to the appropriate queue.
 
Figure 3. Three components of the message
Sample message flow

Sample nonfunctional requirements for the application

Now you'll test these nonfunctional requirements for this scenario:

  • Concurrent users sending requests via applications: 100
  • Expected request completion time: 100 milliseconds
  • Request throughput: 1000 messages per second

Using the Rational Performance Tester generic service client

This section provides instructions for recording a test scenario that simulates the action of sending the test message to the system. You will record a test that puts a message into a WebSphere MQ Input queue, gets processed by the WebSphere Message Broker, and sends the response from the Output queue, where it is picked up by Rational Performance Tester.

Listing 1 shows a sample XML test message.

Listing 1. Sample XML test message
<Code> 
       <HelloMsgHead> 
               <HelloMsg>Hi there!</HelloMsg> 
               <FirstName>User</FirstName> 
               <LastName>One</LastName> 
               <EmailID1>testabc@gmail.com</EmailID1> 
               <EmailID2>testdef@rediffmail.com</EmailID2> 
               <Phone1>9876543211</Phone1> 
               <Phone2>9123456789</Phone2> 
               <Sex>Male</Sex> 
       <!-- End Hello Message Head --> 
       </HelloMsgHead> 
</Code>

To test send this message to the messaging system, follow these steps:

  1. Create a new Performance Test Project by following these steps:
    1. Click File > New > Project.
    2. Select Performance test project and click Next.
    3. Enter the project name and click Finish.
  2. Click Generic Service Client as shown in Figure 4.
Figure 4. Generic Service Client view
Arrow points to icon in menu bar
  1. Configure the Transport protocol:
    1. Click the Transport tab at the bottom, and select Create a WebSphere MQ configuration as shown.
Figure 5. Transport Configurations view
Transport tab, WebSphere HQ option selected
  1. Configure WebSphere MQ protocol:
    1. Enter these values:
      • Name: Name of the protocol configuration
      • Queue Manager Name: Queue manager that you want to connect to in order to send requests
      • Send Queue name: The input and request queue names
    2. Uncheck the Local Queue manager box, and enter the address, port, and client channel of the server where the queue manager resides.
    3. Uncheck the Use Temporary Queue for Response option, and provide the response queue from which the messages are intended to be picked up again by Rational Performance Tester.
    4. Configure correlation:
      • Use Message ID for correlationif you want to identify the response message ID by its request message ID. This is useful in case of advanced XML messages and headers.
      • Use Correlation ID from Request to pick up the messages under response queue is the most common mechanism of identifying the response message based on request correlation ID.
      • UseNo Correlationif you want any and all messages coming to the response queue to be picked up by Rational Performance Tester. This might not lead to any conclusive results, becauseRational Performance Tester will not be able to calculate the time taken for a particular message if it cannot identify the response message with the request message.
      • Uncheck Use RFH2 Header if the message doesn't employ an RFH2 header.
      • Change request type to request for request messages
      • If the communication to messaging system is over a secure channel, provide the security configuration details by checking the Use SSL check box, and configure the SSL connection by clicking Configure SSL and providing the client / server certificates.
Figure 6. Create MQ Protocol configuration dialog window
Needs alt text
  1. Configure WebSphere MQ endpoint request. This request is the XML request sent by the source application to the messaging solution.
Figure 7. Create a WebSphere MQ endpoint request
Arrow points to add an endpoint request
  1. Choose your WebSphere MQ protocol configuration.
Figure 8. Configure Protocol view options
Add EndPoint Request section

Part 2 walks you through preparing the automation script.

Resources

Learn

Get products and technologies

Discuss

Comments

developerWorks: Sign in

Required fields are indicated with an asterisk (*).


Need an IBM ID?
Forgot your IBM ID?


Forgot your password?
Change your password

By clicking Submit, you agree to the developerWorks terms of use.

 


The first time you sign into developerWorks, a profile is created for you. Information in your profile (your name, country/region, and company name) is displayed to the public and will accompany any content you post, unless you opt to hide your company name. You may update your IBM account at any time.

All information submitted is secure.

Choose your display name



The first time you sign in to developerWorks, a profile is created for you, so you need to choose a display name. Your display name accompanies the content you post on developerWorks.

Please choose a display name between 3-31 characters. Your display name must be unique in the developerWorks community and should not be your email address for privacy reasons.

Required fields are indicated with an asterisk (*).

(Must be between 3 – 31 characters.)

By clicking Submit, you agree to the developerWorks terms of use.

 


All information submitted is secure.

Dig deeper into Rational software on developerWorks


static.content.url=http://www.ibm.com/developerworks/js/artrating/
SITE_ID=1
Zone=Rational
ArticleID=841303
ArticleTitle=Test XML messages over WebSphere MQ with Rational Performance Tester: Part 1. Get started
publish-date=10232012