Chapter 6. Deploying the existing sample solution 215
Figure 6-22 Exchange server
When you see your created ITEM go all the way through the approval process
and then get displayed in the exchange server, you have successfully
deployed the approval process and related applications.
Testing the mass update process
There are only two steps to testing the mass aggregation process:
1. Schedule mass update to run.
To schedule the mass update process to run, open a Web browser and go to
http://<hostname>:9080/SchedulerStatus.jsp. This will bring you to the page
showing the current schedule for running mass aggregation. A schedule has
yet to be set, so you should see a page like Figure 6-23 on page 216.
2. To set a schedule for mass update to run click Schedule Task.
216 Using BPEL Processes in WebSphere Business Integration Server Foundation - Business Process Integration and Supply Chain Solutions
Figure 6-23 Schedule page before setting a schedule
3. Figure 6-24 shows the scheduling page. Filling in a starting time of 10
seconds will make the process run 10 seconds. Putting a repeat interval of 10
days will have it run every 10 days after the first invocation.
Figure 6-24 Schedule mass update to run
4. You can enter any times you like, but these are good values for testing
because the process will start soon and only run once. We suggest that if you
want to run it again you should purge the task and re-enter it as shown in
Figure 6-24. Purging the task is discussed later in this chapter.
Chapter 6. Deploying the existing sample solution 217
5. Once you are happy with the times click Submit, which will submit the
schedule and should take you to the page shown in Figure 6-25.
Figure 6-25 A successfully submitted schedule
6. If you now click View Scheduler Status you will be taken to a page similar to
Figure 6-26, which shows the schedule set.
7. You also now have a link for Purge Scheduled Task, which if clicked will purge
the task and take you back to the screen in Figure 6-23 on page 216, from
which you can set a new schedule.
Figure 6-26 View scheduler status and purge task
218 Using BPEL Processes in WebSphere Business Integration Server Foundation - Business Process Integration and Supply Chain Solutions
8. Check the PEAGGOUT queue to see that the data has been sent.
9. The best way to see if the mass update process is running is to look at the
messages on stdout (see “Tip: For viewing stdout:” on page 220). You should
see a number of messages similar to those shown in Example 6-2.
Example 6-2 Sample stdout message for mass update process
SystemOut O Mass Update: Preparing to get all parts from EIS2
SystemOut O -EIS2: Initializing data
SystemOut O -EIS2: Data initialized
SystemOut O -EIS2: Item Passed in <%>
SystemOut O -EIS2: Found key: IN1111113
SystemOut O -EIS2: Found key: IN1111112
SystemOut O -EIS2: Found key: IN1111111
SystemOut O -EIS2: Returning the following XML string: <?xml
version="1.0"?><ExchangeDBroot><Part><ItemNumber>IN1111113</ItemNumber><Price>2
3.98</Price></Part><Part><ItemNumber>IN1111112</ItemNumber><Price>10.20</Price>
</Part><Part><ItemNumber>IN1111111</ItemNumber><Price>2.05</Price></Part></Exch
angeDBroot>
SystemOut O -EIS2: getPartPrice finished
SystemOut O Mass Update: processing item 1 of 3
WebGroup I SRVE0180I: [ExchangeStub2Web] [/ExchangeStub] [Servlet.LOG]:
rpcrouter: init
SystemOut O Attempting to read ExchangeDBFile.xml
SystemOut O Aggregation: aggregating item: IN1111113 (null)...
SystemOut O -EIS3: Initializing data
SystemOut O -EIS3: Data initialized
SystemOut O -EIS3: Returning the following XML string: <?xml
version="1.0"?><ExchangeDBroot><Part><ItemNumber>IN1111113</ItemNumber><Quantit
y>34</Quantity></Part></ExchangeDBroot>
SystemOut O -EIS3: getPartQuantity finished
SystemOut O -EIS2: Item Passed in <IN1111113>
SystemOut O -EIS2: Found price <23.98>
SystemOut O -EIS2: Returning the following XML string: <?xml
version="1.0"?><ExchangeDBroot><Part><ItemNumber>IN1111113</ItemNumber><Price>2
3.98</Price></Part></ExchangeDBroot>
SystemOut O -EIS2: getPartPrice finished
SystemOut O Aggregation: EIS3 result: 34
SystemOut O Aggregation: EIS2 result: 23.98
<Messages deleted>
SystemOut O Mass Update: processing item 3 of 3
SystemOut O Aggregation: aggregating item: IN1111111 (null)...
SystemOut O -EIS3: Returning the following XML string: <?xml
version="1.0"?><ExchangeDBroot><Part><ItemNumber>IN1111111</ItemNumber><Quantit
y>2</Quantity></Part></ExchangeDBroot>
SystemOut O -EIS3: getPartQuantity finished
SystemOut O -EIS2: Item Passed in <IN1111111>
Chapter 6. Deploying the existing sample solution 219
SystemOut O -EIS2: Found price <2.05>
SystemOut O -EIS2: Returning the following XML string: <?xml
version="1.0"?><ExchangeDBroot><Part><ItemNumber>IN1111111</ItemNumber><Price>2
.05</Price></Part></ExchangeDBroot>
SystemOut O -EIS2: getPartPrice finished
SystemOut O Aggregation: EIS3 result: 2
SystemOut O Aggregation: EIS2 result: 2.05
SystemOut O Mass Update: loop complete
If no error messages are shown and you see the last line saying Mass Update:
loop complete, then the process worked.
10.You can also check the PEAGGOUT queue by going to
http://<hostname>:9080/MessageTester/index.html and clicking Get
Message. This will read the first message off the PEAGGOUT queue, which
should correspond to one of the three parts that the mass update handled.
You should be able to run Get Message three times to see all three
messages. Figure 6-27 shows an example.
Figure 6-27 Message off PEAGGOUT

Get Using BPEL Processes in WebSphere Business Integration Server Foundation Business Process Integration and Supply Chain Solutions now with O’Reilly online learning.

O’Reilly members experience live online training, plus books, videos, and digital content from 200+ publishers.