7/30/2019 Getting Started With Oracle SoA V
1/29
Getting Started with Oracle SoA
Creating My First Oracle SOA Project Lab#5
Description:BISP is committed to provide BEST learning material to the beginners and
advance learners. In the same series, we have prepared a complete end-to end
Hands-on Beginners Guide for Oracle SoA. The document focuses on steps involved
in creating 1st Oracle SoA Project. Join our professional training program and learn
from experts.
History:Version Description Change Author Publish Date0.1 Initial Draft Shiva Kant Pandey 21st Aug 20120.1 Review#1 Amit Sharma 29th Aug 2012
www.bispsolutions.com www.bisptrainigs.com www.hyperionguru.com Page 1
http://www.bispsolutions.com/http://www.bisptrainigs.com/http://www.bispsolutions.com/http://www.bisptrainigs.com/7/30/2019 Getting Started With Oracle SoA V
2/29
ORACLE SOA HELLO WORLD PROJECTStep 1: Create new project
New-->All Technologies-->SOA Tier-->SOA project-->OK--> Project Name (HelloWorldProject)-->ADF Business Component-->SOA-->Next-->Empty Composite-->Finish.
Now you can see your project on left pane with all its contents so as we need to start ourproject with XSD .
Step 2: Create a new xsd file under project
Right click on xsd--> file name(HelloWorld.xsd) --> Target
Namespace(http://www.bispsolutions.com/training/soa/schema/Hello)-->
prefix (hwobj) -->ok
now created successfully HelloWorld.xsd as shown in figure :
www.bispsolutions.com www.bisptrainigs.com www.hyperionguru.com Page 2
http://www.bispsolutions.com/http://www.bisptrainigs.com/http://www.bispsolutions.com/http://www.bisptrainigs.com/7/30/2019 Getting Started With Oracle SoA V
3/29
Step 3: Create Hello World xsd as shown below:
Target Namespace
Registered Namespace
Step 4: Click on Design mode & we can see whatever designed in xsd.
www.bispsolutions.com www.bisptrainigs.com www.hyperionguru.com Page 3
http://www.bispsolutions.com/http://www.bisptrainigs.com/http://www.bispsolutions.com/http://www.bisptrainigs.com/7/30/2019 Getting Started With Oracle SoA V
4/29
When we expand by clicking the design is shown below:
Step 5: To create BPEL Process Click on composite .xml
www.bispsolutions.com www.bisptrainigs.com www.hyperionguru.com Page 4
http://www.bispsolutions.com/http://www.bisptrainigs.com/http://www.bispsolutions.com/http://www.bisptrainigs.com/7/30/2019 Getting Started With Oracle SoA V
5/29
This composite .xml is partitioned into three sections1. Exposed Services2. Components3. External references
Now right click on component section and choose BPEL Process.
www.bispsolutions.com www.bisptrainigs.com www.hyperionguru.com Page 5
http://www.bispsolutions.com/http://www.bisptrainigs.com/http://www.bispsolutions.com/http://www.bisptrainigs.com/7/30/2019 Getting Started With Oracle SoA V
6/29
Step 6: Fill all its blank spacesName (HelloWorldProcess)-->NameSpace(Leave as it is)-->Template(Select Synchronous BPELprocess)--->Service Name(HelloWorldService)--->Mark Expose as a SOAP service--->Transaction (required)--->Click on Input Browse to select input of wsdl---> & then Click onOutput Browse to select Output of wsdl
On clicking input browse button you can see as shown below
www.bispsolutions.com www.bisptrainigs.com www.hyperionguru.com Page 6
http://www.bispsolutions.com/http://www.bisptrainigs.com/http://www.bispsolutions.com/http://www.bisptrainigs.com/7/30/2019 Getting Started With Oracle SoA V
7/29
On clicking Output browse u can see as shown below
Step 7: Now we have created BPEL Process as shown below
www.bispsolutions.com www.bisptrainigs.com www.hyperionguru.com Page 7
http://www.bispsolutions.com/http://www.bisptrainigs.com/http://www.bispsolutions.com/http://www.bisptrainigs.com/7/30/2019 Getting Started With Oracle SoA V
8/29
NOTE: In synchronous BPEL Process we can create wsdl automatically as we have already
did in our example HelloWorld
Step 8: Click on Source mode
Step 9: Click on HelloWorldProcess.wsdl in left hand pane (This wsdl is automatically
generated in Synchronous BPEL Process)
www.bispsolutions.com www.bisptrainigs.com www.hyperionguru.com Page 8
http://www.bispsolutions.com/http://www.bisptrainigs.com/http://www.bispsolutions.com/http://www.bisptrainigs.com/7/30/2019 Getting Started With Oracle SoA V
9/29
Step 10: On clicking HelloWorldProcess.wsdl we can see automatic generated wsdl file
www.bispsolutions.com www.bisptrainigs.com www.hyperionguru.com Page 9
http://www.bispsolutions.com/http://www.bisptrainigs.com/http://www.bispsolutions.com/http://www.bisptrainigs.com/7/30/2019 Getting Started With Oracle SoA V
10/29
Scroll Down
Step 11: Click on Design Mode & design of service is shown below:
www.bispsolutions.com www.bisptrainigs.com www.hyperionguru.com Page 10
http://www.bispsolutions.com/http://www.bisptrainigs.com/http://www.bispsolutions.com/http://www.bisptrainigs.com/7/30/2019 Getting Started With Oracle SoA V
11/29
Step12: Since we have already created BPEL Process click on Composite on left pane
To create HelloWorld.bpel click on HelloWorldProcess.
On Clicking, we can see the following :
www.bispsolutions.com www.bisptrainigs.com www.hyperionguru.com Page 11
http://www.bispsolutions.com/http://www.bisptrainigs.com/http://www.bispsolutions.com/http://www.bisptrainigs.com/7/30/2019 Getting Started With Oracle SoA V
12/29
Step 13: Drag assign activity From Component Palette located at Right Pane of window &
keep it in between receive Input & replyOutput .
Right click on assign-->Edit
www.bispsolutions.com www.bisptrainigs.com www.hyperionguru.com Page 12
http://www.bispsolutions.com/http://www.bisptrainigs.com/http://www.bispsolutions.com/http://www.bisptrainigs.com/7/30/2019 Getting Started With Oracle SoA V
13/29
www.bispsolutions.com www.bisptrainigs.com www.hyperionguru.com Page 13
http://www.bispsolutions.com/http://www.bisptrainigs.com/http://www.bispsolutions.com/http://www.bisptrainigs.com/7/30/2019 Getting Started With Oracle SoA V
14/29
Step14 : Click General ----> Name(AssignGreetings)
Step 15: Click on Copy RulesClick Expression Drag it & keep it in Greetings underHelloWorldResponse
Step 16:Click on Concat under String functions --->Click Insert into Expression---> write insideconcat ('Hello::','Greetings')----> OK .
www.bispsolutions.com www.bisptrainigs.com www.hyperionguru.com Page 14
http://www.bispsolutions.com/http://www.bisptrainigs.com/http://www.bispsolutions.com/http://www.bisptrainigs.com/7/30/2019 Getting Started With Oracle SoA V
15/29
Step 17: Click ok
Step 18: Now completed Assign activity, Click Compile tab.
www.bispsolutions.com www.bisptrainigs.com www.hyperionguru.com Page 15
http://www.bispsolutions.com/http://www.bisptrainigs.com/http://www.bispsolutions.com/http://www.bisptrainigs.com/7/30/2019 Getting Started With Oracle SoA V
16/29
Compile Successful
Step 19: Deploy project by clicking HelloWorld Project.
www.bispsolutions.com www.bisptrainigs.com www.hyperionguru.com Page 16
http://www.bispsolutions.com/http://www.bisptrainigs.com/http://www.bispsolutions.com/http://www.bisptrainigs.com/7/30/2019 Getting Started With Oracle SoA V
17/29
Step 20: Deployment Finished.
Note: Before Deployment Start Weblogic Admin Server as discussed in my previous document
Oracle Soa Part IV Doc.
www.bispsolutions.com www.bisptrainigs.com www.hyperionguru.com Page 17
http://www.bispsolutions.com/http://www.bisptrainigs.com/http://www.bispsolutions.com/http://www.bisptrainigs.com/7/30/2019 Getting Started With Oracle SoA V
18/29
Step 21 : Click on Browser icon as shown below:
Step 22: Start your enterprise manager by writing url http: //localhost:7001/em/
Note : Here localhost is application server & 7001 is a port in which enterprise manager isrunning.
Step 23 : Login using credentialsUser Name :weblogicPassword : welcome1click on login
www.bispsolutions.com www.bisptrainigs.com www.hyperionguru.com Page 18
http://www.bispsolutions.com/http://www.bisptrainigs.com/http://www.bispsolutions.com/http://www.bisptrainigs.com/7/30/2019 Getting Started With Oracle SoA V
19/29
Step 24: We have successfully login inside Enterprise manager 11g (Farm_dev_soa)we can clearly observe here that admin server is up & all deployment status is also up it meansthat our admin server is running .Now In left pane of window under Farm_dev_soa click on SOA radio button now again expand& under default we can easily see all the deployed projects.Click twice on HelloWorld Project .
Step 25: Observe that all information regarding to Process Numbers Project is givenRunning instances 0 means that yet we have not tested any instance.
Total 1 but staleProject Status ActiveNow click on Browser tab
www.bispsolutions.com www.bisptrainigs.com www.hyperionguru.com Page 19
http://www.bispsolutions.com/http://www.bisptrainigs.com/http://www.bispsolutions.com/http://www.bisptrainigs.com/7/30/2019 Getting Started With Oracle SoA V
20/29
Step 26 : Click on WSDL URL
Step 27: Now it is a Concrete WSDL , Right click on page & select View Page Source
Now we can see full Concrete WSDL & this wsdl contains Binding & service informationadditionally as shown below:
www.bispsolutions.com www.bisptrainigs.com www.hyperionguru.com Page 20
http://www.bispsolutions.com/http://www.bisptrainigs.com/http://www.bispsolutions.com/http://www.bisptrainigs.com/7/30/2019 Getting Started With Oracle SoA V
21/29
Binding simply means that packaging message in packet with SOAP protocol again a questionarises that what is soap protocol ?SOAP Protocol : SOAP, originally defined as Simple Object Access Protocol, isa protocolspecification for exchanging structured information in the implementation ofWeb
Services in computer networks. It relies on XML Information Set for its message format, andusually relies on other Application Layerprotocols, most notably Hypertext TransferProtocol(HTTP) or Simple Mail Transfer Protocol(SMTP), for message negotiation andtransmission.
Step 28: Copy location address & paste in browser URL & now get the ABSTRACT WSDL &observe it .
www.bispsolutions.com www.bisptrainigs.com www.hyperionguru.com Page 21
http://en.wikipedia.org/wiki/Protocol_(computing)http://en.wikipedia.org/wiki/Web_Servicehttp://en.wikipedia.org/wiki/Web_Servicehttp://en.wikipedia.org/wiki/Computer_networkhttp://en.wikipedia.org/wiki/XML_Information_Sethttp://en.wikipedia.org/wiki/Application_Layerhttp://en.wikipedia.org/wiki/Hypertext_Transfer_Protocolhttp://en.wikipedia.org/wiki/Hypertext_Transfer_Protocolhttp://en.wikipedia.org/wiki/Simple_Mail_Transfer_Protocolhttp://www.bispsolutions.com/http://www.bisptrainigs.com/http://en.wikipedia.org/wiki/Protocol_(computing)http://en.wikipedia.org/wiki/Web_Servicehttp://en.wikipedia.org/wiki/Web_Servicehttp://en.wikipedia.org/wiki/Computer_networkhttp://en.wikipedia.org/wiki/XML_Information_Sethttp://en.wikipedia.org/wiki/Application_Layerhttp://en.wikipedia.org/wiki/Hypertext_Transfer_Protocolhttp://en.wikipedia.org/wiki/Hypertext_Transfer_Protocolhttp://en.wikipedia.org/wiki/Simple_Mail_Transfer_Protocolhttp://www.bispsolutions.com/http://www.bisptrainigs.com/7/30/2019 Getting Started With Oracle SoA V
22/29
Step 29: Copy location address & paste in browser URL & now get the imported xsd &
observe it .
HelloWorld xsd shown below:
www.bispsolutions.com www.bisptrainigs.com www.hyperionguru.com Page 22
http://www.bispsolutions.com/http://www.bisptrainigs.com/http://www.bispsolutions.com/http://www.bisptrainigs.com/7/30/2019 Getting Started With Oracle SoA V
23/29
Step 30 : Copy soap: address location
Paste in Browser & since binding means package or soap envelope so message is envelopedinside soap binding as shown below in red box :
www.bispsolutions.com www.bisptrainigs.com www.hyperionguru.com Page 23
http://www.bispsolutions.com/http://www.bisptrainigs.com/http://www.bispsolutions.com/http://www.bisptrainigs.com/7/30/2019 Getting Started With Oracle SoA V
24/29
Step 31: Click on TEST & create instance
Step 32: Scroll down page & observeService: HelloWorldServicePort: HelloWorldProcessOperation : ProcessView as Tree Viewwrite On blank space "Hello" as Value of Name
www.bispsolutions.com www.bisptrainigs.com www.hyperionguru.com Page 24
http://www.bispsolutions.com/http://www.bisptrainigs.com/http://www.bispsolutions.com/http://www.bisptrainigs.com/7/30/2019 Getting Started With Oracle SoA V
25/29
Step 33: Click on Xml View :
Now observe that the input message is packed inside soap binding Envelope
Click on Test Web Service
And get Response shown below:
Observe response in XML view shown below & click on Launch Flow Trace :
www.bispsolutions.com www.bisptrainigs.com www.hyperionguru.com Page 25
http://www.bispsolutions.com/http://www.bisptrainigs.com/http://www.bispsolutions.com/http://www.bisptrainigs.com/7/30/2019 Getting Started With Oracle SoA V
26/29
Step 34: Faults : 0State : completedDouble Click HelloWorldProcess& see the instance of HelloWorldProcess.
www.bispsolutions.com www.bisptrainigs.com www.hyperionguru.com Page 26
http://www.bispsolutions.com/http://www.bisptrainigs.com/http://www.bispsolutions.com/http://www.bisptrainigs.com/7/30/2019 Getting Started With Oracle SoA V
27/29
Step 35: Click on Flow shown below
Step 36: Click on Receive input on above diagram :
NOTE: Use ALT+ TAB to come again in flow diagram & vise versa.
Step 37: Click on assign Greetings on above diagram :
www.bispsolutions.com www.bisptrainigs.com www.hyperionguru.com Page 27
http://www.bispsolutions.com/http://www.bisptrainigs.com/http://www.bispsolutions.com/http://www.bisptrainigs.com/7/30/2019 Getting Started With Oracle SoA V
28/29
Step 38 : Similarly : Click reply output on above diagram :
Step 39: Click on Faults & check it.
Step 40: Now again double click on HelloWorldProject on left pane & observe that after firstest it created Instance with its instance id & instance state.Now since we have completed our test & wanted to exit from enterprise manager , Click onShutDownTab & then LogOut.
www.bispsolutions.com www.bisptrainigs.com www.hyperionguru.com Page 28
http://www.bispsolutions.com/http://www.bisptrainigs.com/http://www.bispsolutions.com/http://www.bisptrainigs.com/7/30/2019 Getting Started With Oracle SoA V
29/29
Note : In green Box staled instance is indicated which was tested & undeployed after test & soget stale.
Step 41 : Stop Admin server if don't want to further deploy any project
Click Start/stop weblogic servers ----> mark on Admin Server radio ---> Stop