General operation

  1. Configure the client queue manager to send messages using the new adapter by modifying the client queue manager's configuration .ini file so that the Network alias points to com.ibm.mqe.adapters.MQeWESAuthenticationAdapter. Use the following command:
    (ascii)Network=com.ibm.mqe.adapters.MQeWESAuthenticationAdapter
  2. Configure the server queue manager to decode the stream of data that the Client Adapter supplies using either the new adapter or the standard HTTP adapter. Do this by changing the line in the server queue manager's configuration .ini file so that the Network alias points to either com.ibm.mqe.adapters.MQeWESAuthenticationAdapter or com.ibm.mqe.adapters.MQeTcpipHttpAdapter. Use one of the following commands:
    (ascii)Network=com.ibm.mqe.adapters.MQeWESAuthenticationAdapter  
    (ascii)Network=com.ibm.mqe.adapters.MQeTcpipHttpAdapter
  3. Modify the client queue manager code so that the required user ID and password are set before the first network operation is started. For example, insert the following line near the top of your code:
    com.ibm.mqe.adapters.MQeWESAuthenticationAdapter.
    setBasicAuthorization("myUserId@myRealm", "myPassword");
    Replace the parameters with a valid WES Server user ID and password.

    You also need to add code to catch the new MQeException Except_Authenticate after each network operation, in case the supplied credentials were invalid.

  4. Check that the client queue manager can still send messages to the server queue manager without going through the proxy.
  5. Configure the client machine to send HTTP requests through the proxy. Depending on how WES has been configured, the adapter will need to work with either a transparent proxy or an authentication proxy.
    As a transparent proxy
    In this mode, the WES server acts as a simple HTTP proxy. In this case, you need to set the following Java™ application system properties that relate to proxy information:
    http.proxyHost
    Must be set to the host name of the WES proxy
    http.proxyPort
    Must be set to the name of the port that the proxy is listening on
    http.proxySet
    Must be set to true, which tells the adapter to use transparent proxy mode
    The above parameters can be set by adding the following to your Java application:
    System.getProperties( ).put( "http.proxySet",  "true" );
    System.getProperties( ).put( "http.proxyHost", "wes.hursley.ibm.com" );
    System.getProperties( ).put( "http.proxyPort", "8082" );
    The client queue manager's connection to the target MQe server is similar to a connection that doesn't use the WES proxy.
    Figure 1. Administration interface panel
    Screen capture showing Administration interface panel with connection details.

    You need to restart the server and client queue managers for the new settings to take effect. The client should then be able to send messages to the server through the proxy.

    As an Authentication Proxy
    In this mode, the WES server forwards requests to services, based on the URL that you supply. For example, you may want requests for http://wes.hursley.ibm.com/mqe to be forwarded to an MQe queue manager running on mqe.hursley.ibm.com:8082.
    To set this up from MQe you need to update the client's connection reference to the server.
    Target network adapter
    Should point to the Authentication Proxy machine and port
    Network adapter parameters
    Should contain the pathname to the required service

    If you are using the MQe Example Administration tool, select Connection and then Update to configure this.

    Figure 2. Administration interface panel
    Screen capture of the administration interface Update panel showing connection details.
    Note: The reference to the WES Server is entered in the Network adapter field, and the pathname is entered in the Network adapter parms field.
    You need to restart the server and client queue managers for the new settings to take effect. The client should then be able to send messages to the server through the proxy.

Terms of use | WebSphere software

(c) Copyright IBM Corporation 2004, 2005. All rights reserved.