Running WS – Eventing Application Demo using the Filter
Pipeline
Community
Grids Lab,
This document explains how to run the WS Eventing application within the prototype Filter Pipeline. The following assumptions have been made for the purposes of explaining this demo. The user may appropriately change any of these values to suite their needs.
Host: localhost port: 19000 to 22000
Installation directory: c:\webservices\wse as a root directory for WS Eventing application.
Wse Source: - tcp://localhost:19000
Wse Subscription Manager: - tcp://localhost:20000
Wse Sink 1: - tcp://localhost:21000
Wse Sink 2: - tcp://localhost:22000
2.1 Starting Wse Source on Filter Pipeline: - We are assuming host is a localhost and port number for Wse Source is 19000. Using ANT build.xml file we can run the target wse-sink by passing arguments for host name and port number where you want to run the application. Open a MS-DOS command prompt on the Windows OS and change the directory to your WSE installation directory. Execute the following command from directory.
C:\WebServices\wse> ant wse-source -Dwse.source.hostname=localhost - Dwse.source.port=19000
Figure 1 depicts the Source Service running on port 19000.

Figure 1: Source running on port 19000
After successful execution of the above command then type ‘h’ for help at the Wse Source and you will see the options available for you to execute at the Source.

Figure 2: Source with help command
Before executing any commands from this screen, first start the remaining Web Services as follows.
2.2 Starting Wse Subscription Manager on Filter Pipeline: - We are assuming host is localhost and port number for Wse Subscription Manager is 20000. Using ANT build.xml file we can run the target wse-sm by passing arguments for host name and port number where you want to run the application. Open a MS-DOS command prompt on the Windows OS and change the directory to your WSE installation directory. Execute the following command from directory.
C:\WebServices\wse> ant wse-sm -Dwse.submanager.hostname=localhost - Dwse.submanager.port=20000
Figure 3 depicts the Subscription Manager running on port 20000.

Figure 3: Subscription Manager running on port 20000
After successful execution of the above command then type ‘h’ for help at the Wse Subscription Manager and you will see the options available for you to execute at the Subscription Manager

Figure 4: Subscription Manager with help command
2.3 Starting Wse Sink 1 on Filter Pipeline: - We are assuming host is localhost and port number for the Wse Sink 1 is 21000. Using ANT build.xml file we can run the target wse-sink by passing arguments for host name and port number where you want to run the application. Open a MS-DOS command prompt on the Windows OS and change the directory to your WSE installation directory. Execute the following command from directory.
C:\WebServices\wse> ant wse-sink
-Dwse.sink.hostname=localhost
-Dwse.sink.port=21000
-Dwse.source.address=tcp://localhost:19000
Figure 5 depicts the Sink Service running on the port 21000.

Figure 5: Source running on port 21000
After successful execution of the above command then type ‘h’ for help at the Wse Sink and you will see the options available for you to execute at the Sink

Figure 6: Source with help command
You can have multiple Sink’s for demo and we are creating one more Sink as below
2.4 Starting Wse Sink 2 on Filter Pipeline: - We are assuming host is localhost and port number for the Wse Sink 2 is 22000. Using ANT build.xml file we can run the target wse-sink2 by passing arguments for host name and port number where you want to run the application. Open a MS-DOS command prompt on the Windows OS and change the directory to your WSE installation directory. Execute the following command from directory.
C:\webservices\wse>ant wse-sink2
-Dwse.sink2.hostname=localhost -Dwse.sink2.port=22000
-Dwse.source.address=tcp://localhost:19000
Figure 7 depicts the Sink2 web service running on the port 22000.

Figure 7: Sink2 running on port 22000
After successful execution of the above command then type ‘h’ for help at the Wse Sink 2 and you will see the options available for you to execute at the Sink 2 as shown in the Figure 8.

Figure 8: Sink2 with help command
Now all web services are ready on different ports and you have to create link between all web services by following demo below.
3. Running Demo WS Evening after starting:
3.1 Creating links between
different services:
You have to create links between all applications to open to receive and send data across. Use ‘cr’ command as follows.
From Wse Sink 1
cr localhost 20000
cr localhost 19000
From Wse Sink 2
cr localhost 20000
cr localhost 19000
From Wse Source
cr localhost 20000
cr localhost 21000
cr localhost 22000
From Wse Subscription
manager
cr localhost 19000
cr localhost 21000
cr localhost 22000
Above commands creates link between all application and you are ready to send and receive the SOAPMessages between all application.
From the Wse Sink, issue the following command to subscribe to ‘topic’
Sub t Figure 9.depicts the SOAPMessage generated at Sink corresponding to a topic subscription.

Figure 9: SOAPMessage – Request at Sink for Subscription
to the Topic
Wse Source will receive the SOAPMessage for the subscription from the Wse Sink.
Figure 10.depicts the SOAPMessage request at the Wse Source corresponding to the subscription request.

Figure 10: SOAPMessage - Request at Source to the
Subscription.
Wse Source will process the SOAPMessage received from the Wse Sink and store the SOAPMessage in memory and will send the same information to the Wse Subscription Manager. Figure11 depicts the SOAPMessage received from the Wse Source at the Wse Subscription Manager.

Figure 11: SOAPMessage response to the subscription at
Subscription Manager from Source.
Wse Source also sends response back to the Wse Sink saying Subscription is received and you can see the response in the SOAPMessage received at the Wse Sink as below in Figure 12.

Figure 12: SOAPMessage response at Sink to the
subscription to the topic.
Now you are subscribed to the ‘topic’ and you can check the status from the Wse Sink on the existing subscription by issuing following command below.
NOTE: First get the Subscription Identifier from the response received from the Wse Source at Wse Sink.
Status 6b73fd37-f31e-4c3e-a54b-1ebff4396fde (replace it with your own identifier)

Figure 13: SOAPMessage request at Sink
to the status on subscription.
Figure 14 depicts the status response received from the Wse Subscription Manager.

Figure 14: SOAPMessage response at Sink to the status
request
You can renew the subscription from the Wse Sink on the existing subscription by issuing following command below.
NOTE: First get the Subscription Identifier from the response received from the Wse Source at the Wse Sink.
renew 6b73fd37-f31e-4c3e-a54b-1ebff4396fde (replace it with your own identifier)
Figure 15 depicts response received from the Wse Subscription Manager for renew request at the Wse Sink.

Figure 15: SOAPMessage response at Sink to renew
request
You can unsubscribe to the subscription from the Wse Sink on the existing subscription by issuing following command below.
NOTE: First get the Subscription Identifier from the response received from the Wse Source at the Wse Sink.
unsub 6b73fd37-f31e-4c3e-a54b-1ebff4396fde (replace it with your own identifier)

Figure 16: SOAPMessage request at Sink
to unsubscribe
Figure 17 depicts the response received at the Wse Subscription Manager for renew request from the Wse Sink.

Figure 17: SOAPMessage request at Subscription
Manager from Sink to unsubscribe
Wse Subscription Manager will responds to Unsubscribe request from the Wse Sink shown in Figure 18.

Figure 18: SOAPMessage response at Sink for
unsubscribe request
Wse Subscription Manager will send Unsubscribe response to the Wse Sink and notifies the Wse Source that, subscription will be deleted as per the request from the Wse Sink.
SOAPMessage received at the Wse Source from the Wse Subscription Manager as follows at Source Endpoint.

Figure 19: SOAPMessage response at
Souce to unsubscribe request
After successful subscriptions, you can send Notifications from the Wse Source to registered Sink’s be issuing following command from Source.
‘S’ will send topic matching Notifications to the Wse Sink’s as follows. SOAPMessage generated at the Wse Source as follows.

Figure 20: SOAPMessage Notification generated at Source
Notification SOAPMessage received at the Wse Sink as follows.

Figure 21: SOAPMessage notification
received at Sink