Skip to main content

Put new capabilities of business activity monitoring (BAM) to work, Part 8: Enabling WebSphere Business Monitor V6.1 to receive events via WebSphere MQ

Configure WebSphere Business Monitor server to consume WebSphere MQ events

Martin Phillips (mphillip@uk.ibm.com), Software Engineer, IBM
Martin Phillips photo
Martin Phillips is currently a test team leader working on IBM WebSphere MQ. He has worked for IBM since 1999, mainly as a tester for IBM WebSphere Application Server, and particularly with the service integration bus. Recently he was a developer on IBM WebSphere Business Monitor Version 6.1.

Summary:  In this series, learn about the dramatic changes in IBM® WebSphere® Business Monitor V6.1—a major release that extends capability and simplifies how you monitor and manage the performance of your business. WebSphere Business Monitor V6.1 can monitor business process applications running in virtually any environment. In this article, learn how to enable a WebSphere Business Monitor V6.1 server to receive XML-formatted Common Base Events (CBEs) using IBM WebSphere MQ as the transport mechanism.

View more content in this series

Date:  29 Apr 2008
Level:  Intermediate PDF:  A4 and Letter (1161KB | 14 pages)Get Adobe® Reader®
Activity:  2204 views

Introduction

The mortgage lending scenario was first described in Part 3 of this series.

In the mortgage lending business scenario used throughout this series of articles, the implementation of the business process application has not yet been defined. WebSphere Business Monitor can monitor business process applications running in virtually any environment, as long as CBEs can be generated from their activity and transmitted to the monitor model.

If the business process applications are running in IBM WebSphere Application Server, IBM WebSphere Process Server, or IBM WebSphere Enterprise Service Bus, they can use a Common Event Infrastructure (CEI) event emitter factory to get the CBEs emitted to the monitor model. WebSphere Process Server applications are able to automatically emit CBEs if configured to do so in the IBM WebSphere Integration Developer tooling.

If the business process application is not running in a WebSphere Application Server environment, it might not be able to directly access CEI event emitter factories. In this article, learn how to enable business process applications in a WebSphere MQ environment (such as IBM WebSphere Message Broker) to get CBEs to WebSphere Business Monitor.


Prerequisites

To follow the steps in this article, make sure:

  • A business process application capable of creating XML-formatted CBEs and sending the XML as a text message to a WebSphere MQ queue manager has been created.
  • WebSphere Business Monitor 6.1.1 or later is installed.

    If was_root/scripts.wbm/CEIMQ/MQtoCEIMediation.ear is not available on your system, you need to upgrade the WebSphere Business Monitor installation to version 6.1.1 or later.

  • A monitor model that can consume the CBEs generated by your business process application has been created and is installed on the WebSphere Business Monitor server.

Enable WebSphere Business Monitor server to receive events via WebSphere MQ

To prepare your WebSphere Business Monitor server to receive events via a WebSphere MQ queue manager:

  1. Install the MQtoCEIMediation.ear application. It must be installed onto the same server (or cluster) where CEI is configured in the local monitor cell. If you are not sure which server this is, use the administrative console:
    1. Select Service Integration -> Buses.
    2. Select the CommonEventInfrastructure_Bus.
    3. Click Bus Members.

      There should be a single bus member. The name will include the node and server name (or cluster name) that the application must be installed on, as shown in Figure 1.



    Figure 1. CEI bus member


    To install the application from the administrative console on the WebSphere Business Monitor server:

    1. Select Applications > Install New Application.
    2. Click Browse and browse to was_root/scripts.wbm/CEIMQ/MQtoCEIMediation.ear.
    3. Click Next.
    4. On the Select installation options panel, click Next.
    5. On the Map modules to servers panel, make sure the server selected for the AddCEIHeaderMediation module is the one hosting the CommonEventInfrastructure_Bus bus member, as shown in Figure 2.

      Figure 2. Map modules to servers on application install


    6. Click Next.
    7. Click Finish, then save the changes.
  2. From the was_root/scripts.wbm/CEIMQ folder of the WebSphere Business Monitor 6.1 server installation, choose one of the methods below to run the configCEIForMQClients utility.
    • To run the utility interactively, use:
      • For AIX®, HPUX, or Linux®: configCEIForMQClients.sh
      • For Windows®: configCEIForMQClients.bat

      Figure 3 shows sample output from the configCEIForMQClients script.



      Figure 3. Sample output from configCEIForMQClients script


    • To run the utility using a properties file:

      Review the contents of the configCEIForMQClients.props file, and change any necessary properties. The configCEIForMQClients file is an example properties file in the was_root/scripts.wbm/CEIMQ folder. You can create your own properties file for your configuration, as follows, using:

      • For AIX, HPUX, or Linux: configCEIForMQClients.sh –props properties_file_name
      • For Windows: configCEIForMQClients.bat –props properties_file_name

      where properties_file_name represents the name of the properties file that contains the required values for the configuration.

      Figure 4 shows the sample properties file for the configCEIForMQClients script.



      Figure 4. Sample properties file for configCEIForMQClients script


    The configCEIForMQClients utility configures an insecure WebSphere MQ link between WebSphere MQ and the CommonEventInfrastructure_Bus. It also creates a remote queue definition on the WebSphere MQ queue manager called CEIQueue, as shown in Figure 5, which can be used by WebSphere MQ applications to send messages to the CEI server.



    Figure 5. Remote queue definition and transmission queue in WebSphere MQ Explorer


    When running the utility, if the option to connect directly to the WebSphere MQ queue manager is not selected, an MQSC script will be generated. By default, this script is called createMQLink.mqsc. The script must be run against the target WebSphere MQ queue manager to complete the configuration.

    To configure security, see how to Enable security on the WebSphere MQ link.

  3. When the script is completed, restart the local WebSphere Business Monitor server.
  4. Verify that the WebSphere MQ link has started successfully, as follows.
    1. From the administrative console on the WebSphere Business Monitor server, select Service Integration -> Buses.
    2. Click CommonEventInfrastructure_Bus.
    3. Under Topology, click Messaging Engines. One messaging engine should be defined.

      The Status field displays a green arrow if the messaging engine is active.

    4. Click on the messaging engine, then click Additional Properties -> WebSphere MQ links. One link should be defined, as shown in Figure 6.

      The Status field displays a green arrow if the link is active.



      Figure 6. WebSphere MQ Link defined by configCEIForMQClients script


  5. WebSphere MQ applications can now send XML-formatted CBEs to WebSphere Business Monitor by using the CEIQueue destination on the queue manager. The applications do so using:
    • WebSphere MQ JMS text messages
    • WebSphere MQ messages with a format name of MQFMT_STRING

More detail

The configCEIForMQClients utility creates both sides of the WebSphere MQ link and the remote queue definition in queue manager. It also creates a queue on the CommonEventInfrastructure_Bus called CEIQueueAliasForMQ, which will redirect messages to the CEI server’s queue (using a forward routing path). The redirection was necessary because the WebSphere MQ environment cannot address destinations with names longer than 48 characters. The name of the CEI server’s queue is of the format nodeName.serverName.CommonEventInfrastructureQueueDestination, which is very likely to be more than 48 characters long. See figure 7 for an example.


Figure 7. CEIQueueAliasForMQ and the CommonEventInfrastructureQueueDestination

The CEIQueueAliasForMQ is mediated using a service integration bus (SIB) mediation, which adds certain properties to the inbound messages from WebSphere MQ to allow the CEI to process them.


Figure 8. MQ_TO_CEI_Mediation


Enable security on the WebSphere MQ link

See the WebSphere Application Server v6.1 Infocenter and Resources for more information about security on the WebSphere MQ Link.

When enabling security on the MQ Link, make sure you set the Inbound user ID on the foreign bus as a user ID that has authority to connect and send messages to the CommonEventInfrastructure_Bus. You can either configure a new user ID for the CommonEventInfrastructure_Bus or reuse the existing one.

To set the Inbound user ID:

  1. From the administrative console on the WebSphere Business Monitor server, click Service Integration -> Buses.
  2. Click the CommonEventInfrastructure_Bus.
  3. Under Topology, click Foreign buses.

    Click on the foreign bus that represents your WebSphere MQ queue manager.

  4. Under Additional Properties, click WebSphere MQ link routing properties.

    Enter an appropriate Inbound user ID, as shown in Figure 9.

  5. Click OK or Apply, and save your changes.

    Figure 9. Inbound user ID for WebSphere MQ link routing


You can find an existing userid that should have the appropriate authority by looking at the CommonEventInfrastructureJMSAuthAlias J2C Authentication Alias, as follows.

  1. From the administrative console on the WebSphere Business Monitor server, select Security -> Secure administration.
  2. Under Authentication, click Java Authentication and Authorization Service, then click J2C authentication data.
  3. Look at the User ID information for the Alias CommonEventInfrastructureJMSAuthAlias, as shown in Figure 10. This is a user ID that should have authority to connect and send messages to the CommonEventInfrastructure_Bus.

Figure 10. J2C Authentication Alias for the CEI


Problems with creating default AuthorizationToken

If WebSphere Application Server security is not enabled, the following exception may appear in the SystemOut log of the WebSphere Application Server when messages come into WebSphere Application Server from WebSphere MQ:

SECJ5011E: Could not create default AuthorizationToken
during propagation login.  The following exception
occurred: java.lang.NullPointerException

This is a benign exception and can be safely ignored. APAR PK57558, Could not create default AuthorizationToken, resolves this issue.


Summary

In this article, you learned how to configure a link between WebSphere MQ and WebSphere Business Monitor that will allow business process applications in the WebSphere MQ environment to send XML formatted CBEs to WebSphere Business Monitor. The business process application in the WebSphere MQ environment sends text messages containing the XML formatted CBE to the CEIQueue defined on the queue manager. These messages will be transmitted to the WebSphere Business Monitor server's CEI server, which will route the messages to the appropriate monitor model.


Resources

About the author

Martin Phillips photo

Martin Phillips is currently a test team leader working on IBM WebSphere MQ. He has worked for IBM since 1999, mainly as a tester for IBM WebSphere Application Server, and particularly with the service integration bus. Recently he was a developer on IBM WebSphere Business Monitor Version 6.1.

Comments (Undergoing maintenance)



Trademarks  |  My developerWorks terms and conditions

Help: Update or add to My dW interests

What's this?

This little timesaver lets you update your My developerWorks profile with just one click! The general subject of this content (AIX and UNIX, Information Management, Lotus, Rational, Tivoli, WebSphere, Java, Linux, Open source, SOA and Web services, Web development, or XML) will be added to the interests section of your profile, if it's not there already. You only need to be logged in to My developerWorks.

And what's the point of adding your interests to your profile? That's how you find other users with the same interests as yours, and see what they're reading and contributing to the community. Your interests also help us recommend relevant developerWorks content to you.

View your My developerWorks profile

Return from help

Help: Remove from My dW interests

What's this?

Removing this interest does not alter your profile, but rather removes this piece of content from a list of all content for which you've indicated interest. In a future enhancement to My developerWorks, you'll be able to see a record of that content.

View your My developerWorks profile

Return from help

static.content.url=http://www.ibm.com/developerworks/js/artrating/
SITE_ID=1
Zone=Sample IT projects, WebSphere, Architecture
ArticleID=304856
ArticleTitle=Put new capabilities of business activity monitoring (BAM) to work, Part 8: Enabling WebSphere Business Monitor V6.1 to receive events via WebSphere MQ
publish-date=04292008
author1-email=mphillip@uk.ibm.com
author1-email-cc=

My developerWorks community

Tags

Help
Use the search field to find all types of content in My developerWorks with that tag.

Use the slider bar to see more or fewer tags.

Popular tags shows the top tags for this particular content zone (for example, Java technology, Linux, WebSphere).

My tags shows your tags for this particular content zone (for example, Java technology, Linux, WebSphere).

Use the search field to find all types of content in My developerWorks with that tag. Popular tags shows the top tags for this particular content zone (for example, Java technology, Linux, WebSphere). My tags shows your tags for this particular content zone (for example, Java technology, Linux, WebSphere).