Oracle®: SOA Suite 11.1.1.2 Hands-On Workshop OSB Lab 2b
Oracle®: SOA Suite 11.1.1.2 Hands-On Workshop OSB Lab 2b
2
Hands-On Workshop
OSB Lab 2b
3. Select the OSB checkbox and de-select the admin checkbox if the Weblogic Server
and SOA Suite are already running ( which they should be at this point ). If not
running then select it also and click OK.
4. After a few minutes the OSB server should show an OK. Click Close.
2. Open up the Service Bus Console by right-clicking on the OSB Console link in the
browser and selecting Open in New Tab.
4. Under the Change Center pane click the Create button to enable an editing
session.
5. We will now create a Proxy Service (incoming) and Business Service (outgoing)
to take input from the BPEL PermitProcess flow and call the CreditScore web service
we deployed in Lab 2. The Proxy Service will use the same WSDL definition as our
web service so payloads will easily map. Even though this is a simplistic example, it
enforces the notion that all messaging in our design will be brokered by the service
bus.
In the bottom left hand side of the page click on the Project Explorer link.
6. Enter a new project named CreditScore and click the Add Project button.
8. Create a new folder under this project called Schemas: Enter Schemas as the
folder name and click the Add Folder button.
10. Import the WSDL to be used for our Proxy Service. In the Resources section on the
page click on the Select Resource Type drop down box and select WSDL:
11. Give the new Resource Name CreditScore and browse to the
CreditScoreService.wsdl file in the /home/oracle/MyFiles directory. Select the file
click Open.
13. Under the Project Explorer pane on the left center of the page click the CreditScore
project to navigate back to the parent level.
14. In the Resources section on the page click on the Select Resource Type drop
down box and select Business Service:
15. Enter the Service Name as: CreditScoreBusiness, check the WSDL Web Service
radio button and click the Browse button to select a WSDL:
16. Under the Select a WSDL dialog page click the CreditScore wsdl link.
17. Under the Select WSDL definition dialog page select the CreditScorePort and
click Submit. You will be return to the Create a Business Service dialog.
18. Click Next > >. In the Transport Configuration dialog set the following:
a. Load Balancing Algorithum: none
b. Ensure that the Endpoint URI is:
http://localhost:7001/CreditScore/CreditScorePort
You should end up with:
19. Click the Last > > button. The areas we modified will be displayed in the final
configuration:
10
20. Click Save. The definition of the Business Service is complete. Complete the editing
changes for this session by clicking the Activate button in the Change Center
pane and then Submit in the Activate Session dialog.
21. Start a new editing session for the creation of the Proxy Service by clicking Create
in the Change Center pane.
22. Under the Project Explorer pane on the left center of the page click the CreditScore
project.
23. In the Resources section on the page click on the Select Resource Type drop
down box and select Proxy Service:
11
24. Enter the Service Name as: CreditScoreProxy, check the WSDL Web Service
radio button and click the Browse button to select the WSDL:
12
27. Click the Last > > button. The areas we have configured will be displayed:
28. Click Save. The definition of the Proxy Service is complete. Our project should now
contain two services:
13
29. Now, we will define a message flow that tol route the XML payload coming into the
CreditScoreProxy Proxy Service to the CreditScoreBusiness Business Service.
This is where will you do any transformations, routing rules, etc. In our case, since
the WSDL used in both services is the same, no special transformation has to take
place.
Click the Edit Message Flow icon in the CreditScoreProxy service:
14
32. Click on the RouteNode1 icon and select Edit Name and Comments:
15
35. Click the Add an Action link and select Communication Routing:
16
37. In the Select Service dialog check the radio button for CreditScoreBusiness and
click the Submit button.
38. Back at the Edit Stage Configuration dialog select the CreditScore Operation
from the drop down box:
17
39. Back at the Edit Message Flow page we will add a stage into the response pipeline so
that we can log the <score> response from the CreditScore web service. This will
proof out execution of this flow. Click on the Response Pipeline stage and select
Add Stage.
18
42. Click on the Log Response stage and select Edit Stage.
19
NOTE: This expression takes the returned <score> value from the CreditScore web service
and wraps text around it.
49. Click the Save All button. The message flow is now completed.
20
50. The definition of the Business Service is complete. Complete the editing changes for
this session by clicking the Activate button in the Change Center pane and then
Submit in the Activate Session dialog.
51. Once the project is saved you can test drive the Proxy Service by selecting the
CreditScore project in the Project Explorer pane and clicking on the Launch
Test Console icon of the CreditScoreProxy service inside the Resources section of
the page.
52. The CreditScore web service returns data based on the value of the first character of
the SSN. SSNs starting with a 3 should return 721 upon successful execution. Those
starting with a 2 will return 644 and those starting with a 1 will return 583. Enter
321-45-6666 into the SSN field in place of the default value of string. Click the
Execute button.
21
53. Click the Back button to retest. Enter a SSN that starts with a 2 and finally the do
a last test with the value beginning with a 1. Confirm the results:
22
These Proxy and Business services will now to be used in the BPEL Lab.
23