Yesterday I wrote about the SOA Monitor, an important feature in the Integrated SOA Gateway. Today we will see another important component, the Service Invocation Framework or SIF.
Links to related posts:
- Oracle E-Business Suite R12.1 – Integrated SOA Gateway Provides Native, Out-Of-The-Box SOAP Based Web Services
- Oracle E-Business Suite R12.1 – Integrated SOA Gateway’s SOA Monitor
The Service Invocation Framework (SIF) is built on top of the Business Event framework. I will not go into the details of Business Events, Workflow etc in this post. I will show you how to create a Business Event & Subscription to invoke a EBS SOAP based web service. In the next post I will cover calling a 3rd party SOAP based web service.
We will use the same PL/SQL based web service, FND_PROFILE, that we generated and used in part 1 of this series. The first step is to create a new Business Event. Log in to your EBS R12.1 instance with a user that has the Workflow Administrator Web Applications Responsibility and select Business Event from the menu to go to the Search Business Events page.
Fig 1. The Business Event search page
Click the Create Event button on the Search Business Event page to create a new Business Event. You will need to provide:
- A Name for you new Business Event
- A Display Name
- The Owner – we will just use “Oracle Workflow”
- The Owner Tag – we will use “FND”
Fig. 2. New Business Event created
Next we need a Subscription for our Business Event. Navigate back to the Business Event search page and search for the newly created Business Event. Note that the Business Event does not have any Subscriptions at this time.
Fig 3. No Subscriptions in Business Event
Lets create a new Subscription. Click the Subscriptions icon.
Fig 4. No Subscriptions in our new Business Event
Click the Create Subscription button.
Fig 5. Creating a new Subscription
We need the following information:
- The Subscriber System
- The Execution Condition – Phase: We want a synchronous web service call. So set it to a value less than 100. We used 50 here.
- The Action Type – Set it to “Invoke Web Service”
Click the Next button.
Fig 6. The Load WSDL page
Now we need the WSDL link to the EBS SOAP based web service we want to invoke. We can copy the link from the Integration Repository page for the FND_PROFILE service and paste it here. The Service Invocation Framework will load and parse the WSDL when we click the Next button.
Fig 7. Select Service
SIF has parsed the WSDL and extracted the necessary details. Select the Service and click the Next button.
Fig 8. Select the Service Port
On the next page select the Service Port and click the Next button.
Figure 9. Select the Operation
In the Select Operation screen SIF will list all the Operations exposed by the WSDL. We want to use the GET operation. Select it and click the Next button.
Fig 10. The Subscription Documentation page
The Subscription Documentation page needs a number of important Parameters:
- WFBES_CALLBACK_EVENT = oracle.apps.fnd.soa.CallBackEvent
- WFBES_CALLBACK_AGENT = WF_WS_JMS_IN
- WFBES_SOAP_USERNAME = <user name to be used for service invocation>
- WFBES_SOAP_PASSWORD_MOD = <Text value used for FND_VAULT lookup of user password>
- WFBES_SOAP_PASSWORD_KEY = <Text value used for FND_VAULT lookup of user password>
The WFBES_CALLBACK_EVENT & WFBES_CALLBACK_AGENT are self explanatory. The WFBES_SOAP_USERNAME parameter value will be used by SIF in the WSSE Header of the SOAP message. We also need a password and instead of leaving it in clear text as a Subscription Parameter, SIF uses the DB Vault to retrieve the password.
To store the password in the DB Vault, use the following command:
@$FND_TOP/sql/afvltput.sql <Password Mod> <Password Key> <password>
e.g.,
@$FND_TOP/sql/afvltput.sql ws_caller_pwd ws_caller_pwd_key sysadmin
Fig 11. Storing password in DB Vault
To verify the stored password, use the following SQL:
select fnd_vault.get ( '<Password Mod>', '<Password Key>' ) from dual;
e.g.,
select fnd_vault.get ( 'ws_caller_pwd', 'ws_caller_pwd_key' ) from dual;
Fig 12. Checking the password stored in DB Vault
Okay. Back to SIF. We specify the Mod & key for password retrieval from the DB Vault as the WFBES_SOAP_PASSWORD_MOD & WFBES_SOAP_PASSWORD_KEY parameters respectively.
Click the Apply button to create the new Subscription.
Fig. 13. Subscription created
Now we are ready to use our Event & Subscription to invoke the FND_PROFILE web service. Search for the Business Event we created earlier and click the Test icon.
Fig 14. Use the Test Business Event feature
Note: The Test functionality is available only for quick testing of Business Events. Typically you will use a Workflow to invoke the Business Event but as I mentioned at the beginning we will not go into all that. Our purpose here is to create a Business Event with SIF technology and invoke a EBS SOAP based web service. So we will click the Test button!
Fig 15. Raise Business Event in Java
While creating our new Subscription, we specified the user name to be used for the invocation. We also stored a password in the DB Vault and passed parameters to our Subscription for retrieval of the password at runtime. Now the user name and password will be used to create the WSSE Header and only help us pass the first hurdle, Authentication.
We also need to tell the Integrated SOA Gateway to Authorize us. That means we need to pass on our Responsibility, Application, Security Group ID, Organization ID and the NLS Language. We do this as an Event Parameter during service invocation. The WFBES_INPUT_HEADER header’s value is a XML fragment comprising the SOAHeader.
<SOAHeader xmlns:ns0="http://xmlns.oracle.com/apps/fnd/soaprovider/plsql/fnd_profile/">
<ns0:Responsibility>FND_REP_APP</ns0:Responsibility>
<ns0:RespApplication>FND</ns0:RespApplication>
<ns0:SecurityGroup>STANDARD</ns0:SecurityGroup>
<ns0:NLSLanguage>AMERICAN</ns0:NLSLanguage>
<ns0:Org_Id>204</ns0:Org_Id>
</SOAHeader>
Now comes the actual payload that will form the body of our SOAP message.
<InputParameters xmlns="http://xmlns.oracle.com/apps/fnd/soaprovider/plsql/fnd_profile/get/">
<NAME>FND_ANTIVIRUS_SERVER</NAME>
</InputParameters>
Put the data in the appropriate places in the UI and click the “Raise in Java” button. This causes SIF to invoke the EBS SOAP based web service from the middle tier Java code instead of from the database layer and PL/SQL. In conjunction with the Execution Phase (value of < 99), this determines whether the invocation will be synchronous or asynchronous.
The web service will be invoked and the response (XML) displayed in a new Text Box at the bottom of the page.
Fig 16. Response from EBS SOAP based web service to invocation from SIF
Well, that’s it. The Service Invocation Framework of the Integrated SOA Gateway allows SOAP based web service invocation from an EBS instance. Tomorrow I will show how to use the same infrastructure to invoke a 3rd party, SOAP based web service.
This of course opens up endless possibilities for Integration. Given that you can expose EBS APIs as SOAP based web services to the external world and also invoke such web services from the EBS middle tier as well as the database level via PL/SQL, opens up hereto hidden vistas for Integration of EBS with other software systems.
No related posts.
Related posts brought to you by Yet Another Related Posts Plugin.


















No comments.