Upload
sreesree
View
216
Download
0
Embed Size (px)
Citation preview
8/10/2019 1.Develop a synchronous service for addition of two numbers (1).docx
1/37
8/10/2019 1.Develop a synchronous service for addition of two numbers (1).docx
2/37
Now open the browser and give the following url:
http://localhost:7001/console
user name: weblogic
password: welcome123
now under murali_domain/environment/servers
we can see the admin server up and running:
http://localhost:7001/consolehttp://localhost:7001/consolehttp://localhost:7001/console8/10/2019 1.Develop a synchronous service for addition of two numbers (1).docx
3/37
8/10/2019 1.Develop a synchronous service for addition of two numbers (1).docx
4/37
Now if we refresh in the admin console the status of the soa_server will be changed to running as shown below:
3 . Now open the Jdeveloper
The Jdeveoper view will be as shown:
8/10/2019 1.Develop a synchronous service for addition of two numbers (1).docx
5/37
8/10/2019 1.Develop a synchronous service for addition of two numbers (1).docx
6/37
Now you will be prompted for type of server you want to create:
8/10/2019 1.Develop a synchronous service for addition of two numbers (1).docx
7/37
Select standalone server and click on Next>
You will be prompted for app server connection name as shown below:
8/10/2019 1.Develop a synchronous service for addition of two numbers (1).docx
8/37
Provide name of your choice. In my case it is murali_appserver and click on Next>
You will be prompted for weblogic server password:
8/10/2019 1.Develop a synchronous service for addition of two numbers (1).docx
9/37
Provide the password that you have used during installation:
In my case it is welcome123.
Now click on Next>
You will be prompted for domain name and port details:
8/10/2019 1.Develop a synchronous service for addition of two numbers (1).docx
10/37
Provide the details as shown above and click on Next>
Now you can test the app server connection by clicking on test buttion.
If everything is fine then you will get success message as shown below:
8/10/2019 1.Develop a synchronous service for addition of two numbers (1).docx
11/37
Now click on Finish.
This completes the appserver connection creation.
3. Creating New Application:
An application is a higher level component which can have multiple projects.
New application can be created by file/new:
Now select SOA application available under the current project
technologies/general/Applications
8/10/2019 1.Develop a synchronous service for addition of two numbers (1).docx
12/37
Now click on Ok
Now provide the application name as shown below:
8/10/2019 1.Develop a synchronous service for addition of two numbers (1).docx
13/37
Now click on next>
Now provide the project name as shown below:
8/10/2019 1.Develop a synchronous service for addition of two numbers (1).docx
14/37
8/10/2019 1.Develop a synchronous service for addition of two numbers (1).docx
15/37
Once you click on finish our application and project will be created and prompted for
creation of our bpel component as shown below:
8/10/2019 1.Develop a synchronous service for addition of two numbers (1).docx
16/37
For the Bpel process provide the details required:
Name: give some meaningful name say for ex., SynchAddProcessor
Namespace: either you can leave the default value provided for this or change what
ever you want:
http://xmlns.friendzcorps.com/MorningBatchPracticse_jws/SynchAdd/SynchAddProcessor
Under template drop down select Synchronous bpel process.
now click on ok.
This has completed creating our basic components
For any bple project there will be one default xsd will be created and will be available
under xsdfolder name. in our case the file name is SynchronousAddProcessor.xsd.
double click on this folder, you can see its contents editing area.
http://xmlns.friendzcorps.com/MorningBatchPracticse_jws/SynchAdd/SynchAddProcessorhttp://xmlns.friendzcorps.com/MorningBatchPracticse_jws/SynchAdd/SynchAddProcessorhttp://xmlns.friendzcorps.com/MorningBatchPracticse_jws/SynchAdd/SynchAddProcessorhttp://xmlns.friendzcorps.com/MorningBatchPracticse_jws/SynchAdd/SynchAddProcessorhttp://xmlns.friendzcorps.com/MorningBatchPracticse_jws/SynchAdd/SynchAddProcessor8/10/2019 1.Develop a synchronous service for addition of two numbers (1).docx
17/37
8/10/2019 1.Develop a synchronous service for addition of two numbers (1).docx
18/37
The bpel will be used for implementing business functionality. Here the functionality is
nothing but get the request(consisting of two numbers), perform the addition of those
two numbers and return the result.
Now we have to build an arithmetic expression (sum = number1+number2).
For this drag and drop the assign activityfrom component palette as shown below:
8/10/2019 1.Develop a synchronous service for addition of two numbers (1).docx
19/37
Now double click on the assign activity. Now the assign activity will be opened. Select
copy operation available under copy operationtab.
E
Now the create copy operation window will be displayed as shown below:
8/10/2019 1.Develop a synchronous service for addition of two numbers (1).docx
20/37
The left hand side variables are the ones based on which we want to build our
expression(number1+number2)
Right hand side variable are the ones to whom we want to assign the result. In our case
we have to assign to sum available under out put variable :
Now we have to buld the expression number1+number2.
For this purpose select expression under type in from
8/10/2019 1.Develop a synchronous service for addition of two numbers (1).docx
21/37
Now click on the expression bulder as shown below:
8/10/2019 1.Develop a synchronous service for addition of two numbers (1).docx
22/37
Now the expression builder will opened as shown below:
8/10/2019 1.Develop a synchronous service for addition of two numbers (1).docx
23/37
Now expand input variable till number1 and number 2 as shown below:
8/10/2019 1.Develop a synchronous service for addition of two numbers (1).docx
24/37
Now select number 1 and click on insert in to expression. this will inser the number1 in
to the expression area as shown below
8/10/2019 1.Develop a synchronous service for addition of two numbers (1).docx
25/37
Now place the operator + at the end of the expression and insert the number2 as we
did for number1.
The final expression will looks like blelow:
8/10/2019 1.Develop a synchronous service for addition of two numbers (1).docx
26/37
Now click on okNow you can see expression in from area as shown below:
8/10/2019 1.Develop a synchronous service for addition of two numbers (1).docx
27/37
Now the result has to be assigned to sum available under output variable. For this
expand the output variable till sum and select thesum.
8/10/2019 1.Develop a synchronous service for addition of two numbers (1).docx
28/37
Now click on ok. This will completes our copy operation and will return to assign
window as shown below:
Now click on apply and click on ok.
This has finished developing our service.
8/10/2019 1.Develop a synchronous service for addition of two numbers (1).docx
29/37
Now click on saveall.
Next we need to build(compile) our prject. For this purpose right click on the SynchAdd
project and click on make SynchAdd.jpr
If everything is fine we will b e getting 0 errors and 0 warnings under bpel
log/Messages.
Next we need to deploy our application to soa server. For this right click on SynchADD
and say deploy as shown below:
8/10/2019 1.Develop a synchronous service for addition of two numbers (1).docx
30/37
Now follow the below screen shots to get it deployed:
8/10/2019 1.Develop a synchronous service for addition of two numbers (1).docx
31/37
Click on next>
Click on Next>
Select the application server connection(murali_appserver) and click on next
8/10/2019 1.Develop a synchronous service for addition of two numbers (1).docx
32/37
Now select our soa_server(by default selected) and click on next>
8/10/2019 1.Develop a synchronous service for addition of two numbers (1).docx
33/37
Now click on next>
8/10/2019 1.Develop a synchronous service for addition of two numbers (1).docx
34/37
Click on finish>
This will start the deployment process
If everything went well we can see our component got deployed successfully under
deployment log.
8/10/2019 1.Develop a synchronous service for addition of two numbers (1).docx
35/37
Now we need to test our composite. For this go to em console
http://murali:7001/em/
provide the user name and password that you have given during installation .
user id: weblgoic
password: welcome123
After logging in expand the farm_murali_domain/soa/soa_infra/default
This is the place where all of our deployed composites will be available.
http://murali:7001/em/http://murali:7001/em/http://murali:7001/em/8/10/2019 1.Develop a synchronous service for addition of two numbers (1).docx
36/37
Just click on our synchAdd this will load the default test environment on right side as
shown below: here click on test
Now come down and provide the input as shown below and click on test webservice:
8/10/2019 1.Develop a synchronous service for addition of two numbers (1).docx
37/37
Now you can see the result(sum)
Now if you want to test the web service again repeat the process.