Running the scenarios

Before you run the scenarios:

  1. Start the adapter for iSoft if it is not already running.
  2. Start the Visual Test Connector if it is not already running.
    1. Click File->Create/Select Profile. A new window pops up. If it's the first time executing the sample, then click File->New Profile.
    2. Select PortConnector.cfg from the sample_folder directory.
    3. Set the Connector Name field to PortConnector.
    4. Set the Broker Type name to WMQI.
    5. Select PortConnector from the list.
    6. Click OK.
    7. Click File->Connect.
  3. Start iSoft components
    1. Copy instances of icsmqd and icssvr to the sample_folder\icssvr directory
    2. Set the following environment variables:
      P2PMBSERVER_INPUTURI=http://127.0.0.1:3081
      

      P2PMBSERVER_MBNAME=wbia.queue.manager
      

      These variables will be read by the iSoft WebSphere MQ driver (icsmqd) when it is started. If wbia.queue.manager is not the name of your queue manager, substitute your queue manager's name.

    3. Start one instance of the iSoft WebSphere MQ driver.
    4. Open three instances of the iSoft Commerce Suite server.
    5. In the first window enter the following:
      batch icssvr.cfg_a
      

      This instance will be referred to as Commerce Server A

    6. In the second window, enter the following:
        batch icssvr.cfg_b
      

      This instance will now be referred to as Commerce Server B

    7. In the third window, enter the following:
       batch icssvr.cfg_c
      

      This instance will now be referred to as Commerce Server C

Request processing scenario

This part of the tutorial describes a request processing scenario.

  1. Load the business object
    1. Using the Test Connector, load a copy of Company_A_Fruit_Catalog_with_dynamic_mo.BO by selecting Edit->Load BO. If the Load BO menu option is unfocused, click in the left grid pane and try selecting Edit->Load BO again.
    2. When you are prompted for a name, enter A_send. Examine the business object, expanding its child objects. Notice that when you expand JMSProperties the attribute receiverid has the value B. This information is included in the RFH2 header. It tells the iSoft Commerce Suite server to forward the message to a trading partner named B.
  2. Send the business object to trading partner B
    1. Click the Send BO button. This posts a message to the COMPA.OUT queue. Commerce Server A must now get the message and send it to its trading partner.
    2. In the Commerce Server A window, enter the following:
      send http MAILBOX MAILBOX -de -dsMAILBOXID=COMPA.OUT -r
      

      Alternatively, to start a persistent send command that continually polls the queue every 5 seconds until April 15th 2003 invoke the following command

      send http MAILBOX MAILBOX -de -dsMAILBOXID=COMPA.OUT -r 
      -tC5s -tE20030415000000
      

    After performing a successful send you'll notice that both the Commerce Server A and Commerce Server B windows contain new log messages.

  3. Send the business object to trading partner C
    1. Edit the business object instance A_send. Set the value of MOConfig.JMSProperties.receiverid to C.
    2. Click the Send Bo button.
    3. In the Commerce Server A window, enter the following:
      send http MAILBOX MAILBOX -de -dsMAILBOXID=COMPA.OUT -r
      

    The message is delivered to trading partner C.

  4. Confirm message delivery
    1. Check the file system. There should be new files in sample_folder\icssvr\inboxB\fromA and sample_folder\icssvr\inboxC\fromA.
    2. New messages should exist in the COMPA.RECEIPTS and COMPA.NOTICES queues.

Event notification scenario

In the following scenario Trading Partner B sends an order to Trading Partner A. The iSoft Commerce Suite server has the ability to route messages to different queues based on a messages MIME type. In this scenario you create messages with a text/xml MIME type. The addroute commands in icssvr.cfg_a route these messages to the COMPA.XML queue. Commerce Server A could also route any messages with a MIME type set to text/plain to COMPA.TXT. You can configure the connector to poll these queues and configure data handlers to process the MQ messages on a per queue basis. An XML data handler could process all messages on a specific queue (such asCOMPA.XML). The delimited data handler could process all messages on another queue (for example, COMPA.TXT). The following sample demonstrates polling XML messages only

  1. Process incoming trading partner messages
    1. Invoke the following send command in Commerce Server B.
      send http B A -cX -fNoutboxB\toA\Order1.txt
      

      This command gets a file from the file system and transports it from Commerce Server B to Commerce Server A. Commerce Server A puts the message in the COMPA.XML queue.

    2. Alternatively, to send information to Commerce Server A and deposit it in the COMPA.TXT queue, you could have entered the following command:
      send http B A -cT -fNoutboxB\toA\Order1.txt
      
  2. Confirm message arrival
  3. Poll for the message
  4. Check the Test Connector for the processed objects
    1. You should see three objects in the right hand pane:
      • a Sample_ISoft_Notification object
      • a Sample_ISoft_MDN object
      • a Sample_ISoft_Order object
    2. Double click each object to inspect it.
    3. Select each object separately and click the Reply Success button.

    Note:
    Be sure to click Reply Success or Reply Fail for each object before shutting down the connector.

If you have performed all the above steps successfully, you should have a working sample scenario that enables the iSoft adapter to send and receive messages from the iSoft Commerce Suite server.

Copyright IBM Corp. 1997, 2004