Step 6. Now we will be creating the service bus project(you can create any project). Select service bus project and click ok.
Step 7. Provide your project name and click on finish.
Step 8. Next, We will create the folder for xsd/wsdl.
Right click on project-->Gallery-->folder.
Provide folder name as XSD
Similarly, for WSDL
Step 9. Next, we will be creating the XSD.
right click on XSD-->New-->XML Schema
Provide xsd name, select the directory and TargetNamespace details.
Step 10. We have generated the basic structure of the xsd file, which got generated by jdeveloper.
Step 11. Now as our requirement is to have EmployeeRequest as Input and EmployeeResponse as Output, we will update the generated xsd.
Changed the Name ElementName--> EmployeeRequest
right click on the EmployeeRequest-->Insert After element-->element, to get the EmployeeResponse element.
right click on EmployeeRequest-->Insert Inside element-->sequence
right click on sequence-->Insert Inside sequence-->element
Similarly, you can create sequence & multiple elements inside EmployeeResponse.
Update the elements name as per the requirement.
Final xsd in design view.
Final xsd in source view.
Step11. Next we use the above created xsd file for the creation of wsdl file by using wsdl Builder.
right click on the wsdl folder-->New--> WSDL(builder)
You will get the below create WSDL screen, update all the details:-
File Name:- Provide Name of your wsdl file.
Directory:- Where you want to keep your wsdl file.
Namespace:- Provide xsd namespace.
Binding: Provide binding name.
Create Port Type:- If you don't have any port and want to create new.
- Port Type: provide Port Type name.
- Operation: provide Operation name.
Select Port Type:- Use existing port.
Interface Type:- Select One-Way, if only one way request you have, (in this case we only need to provide request details) else select synchronous, if you have 2-way request/response, in this case we need to provide both request and response elements details.
In our case, we have both request and response, so I have selected the Interface Type as Synshronous Interface
Now, as we have mentioned all the above details, except the Input/Output/Fault part.
Next, we will configure the Input/Output elements only, as we don't need fault.
click on + icon, as shown in the Input.
Give message part name and select the glass icon(as shown) to select the dataType for Input element.
After selection, it will look like this:-
Similarly
, for the Output elements configuration:-
After providing Input/Output details, click on ok.
Our WSDL file design view:-
Our wsdl file in source view:-
NOTE:-Here we have created the wsdl by importing the xsd, so lets validate the wsdl by calling the xsd.
Move the cursor over the schemalocation path and click over it with ctrl button(ctrl+click), you should be able to open the xsd, if everything is correct.
Similarly, for request and response variable
Ctrl+click over the “inp1:EmployeeRequest” you should be able to get the below screen.
Similarly for response and other elements.
This is how you will create the xsd-->WSDL-->Validate.
Hope, this might help you.
please let me know in case you need further details.