Message Oriented Middleware (MOM) is a category of connectivity middleware that provide program-to-program communications by message passing.
MOM, because it generally supports multiple protocols, comprises an infrastructure that will support reliable and scalable high-performance distributed application networks. Most Message Oriented Middleware is implemented with queued message store-and-forward capability and it is this feature Portus supports.
In particular the systems supported by Portus are IBM WebSphere MQ and Software AG EntireX Broker.
There are 2 ways to integrate a messaging sytem with Portus.
Tutorials are available which demonstrate these 2 capabilites.
The first tutorial uses Portus to write usage governance data to a messaging system and a second Portus to process these and store them in a database. See here for details on this.
This tutorial uses a Java client to access the WSDL of a web service supporting MQ and call it using SOAP over MQ. See here for details on this.
In this tutorial we will be using 2 Portus servers. One will direct usage governance data collected to a message queue and the other will read from this queue and process the input. The end result is that the target of the usage governance web service will receive an add request complete with the data.
Select the Governance tab in the Properties view.
To turn data collection on the Information box must be selected. If required Input Data and Output Data may also be selected.
The Messaging section allows one to enter the details required for None, MQ or EntireX :
Select the radio button of MQ or EntireX and fill in as appropriate for you MOM installation. Note that the queue will be opened for output and later on in this tutorial will be opened as an input queue.
At this point Portus should have connected successfully to the manager and opened the output queue specified. Check the error log for any errors at this point.
The default location of the Apache error_log is [SERVER_INST]/Apache22/logs/error_log replacing [SERVER_INST] with the location in which you have installed Portus.
An add request, containing usage governance data pertaining to this request, should appear as an entry in the output queue.
Use a search mechanism particular to your messaging system to check that this is the case. Note the syntax of this request is supported by the usage governance web service.
If the latter has not yet been created, follow the steps outlined here to do so.
In the Control Centre, select the second Portus server. Open the Messaging tab in the Properties view for the usagegovernance web service:
Portus will now make contact with the appropriate messaging system. Check the error log for messages.
The default location of the Apache error_log is [SERVER_INST]/Apache22/logs/error_log replacing [SERVER_INST] with the location in which you have installed Portus.
As soon as successful connections have been made, the input queue/service will be read and the message(s) processed.
There are a couple of ways to check the status of this.
Portus and IBM MQ Series can be used together to enable sending SOAP requests to an MQ queue and to receive a response from a queue.
These request are asynchronous so it means that multiple requests may be sent from the client even though Portus may not be running.
These requests are held on the queue until Portus reads and processes them. Likewise the responses will reside on a queue until such time that a client may request them.
Here is a top level view on the steps involved.
This tutorial will make use of Java wrapper/stub classes to access a Portus web service.
Java wrapper/stub classes are generated using the Apache Axis2 feature WSDL2Java.
If you do not have it already, download and install the latest Axis2 kit.
The web service which we will be using is that generated by discovering the city table in the World database supplied by a MySQL installation. See MySQL Tutorials for details on how this is achieved.
Ensure that the MQ Manager to be used has been started and that an input and output queue created. Also ensure that a listener has been started.
Select the world_dsn_city web service and open the Messaging tab. Select the MQ radio button and tab. Fill in the details appropriate to your MQ installation.
Portus will now make contact with the appropriate messaging system. If an error occurs it will be highlighted as follows.
Check the error_log to find the cause. The default location of the Apache error_log is [SERVER_INST]/Apache22/logs/error_log replacing [SERVER_INST] with the location in which you have installed Portus. Please correct and try again.
If successful then carry on to next step.
Open a command prompt (aka "DOS box"), change to the "SOAPMQTutorial\src" directory and run the following command:
wsdl2java -uri http://<yourserver>:<yourport>/world_dsn_city?WSDL -o ..\ -p SoaGW
The following items are generated from the Portus WSDL:
Right-click on SOAPMQTutorial and select Build Path -> Add External Archives...
Navigate to where mqTransports-0.1.jar was saved and select Open to add it the project.
Right-click on SOAPMQTut.java and select Run As -> Java Application:
The output appears in the "Console" window:
![]() ![]() |
![]() |
![]() ![]() |