Title: Interoperability between heterogeneous applications using Web Services
1Interoperability between heterogeneous
applications using Web Services
- by
- Esther Shailaja Campbell
- Advisor Dr. Stewart Shen
- Student ID _at_00066220
- Email epakalap_at_cs.odu.edu
2Presentation Features
- Objective
- Modules
- Web Service WSDL
- Architecture
- Creating Consuming Web Services
- Scenario
- Demo
- Future work
- QA
3Project Objective
-
- The main Objective of this project is to
demonstrate Interoperability between Java and
.Net applications using Web Services -
4Software used
- Java application Apache Tomcat Web Server, Java,
JSP, Servlets, Apache Axis SOAP, WSDL2Java
Java2WSDL tools etc and MySQL Database - .Net Application IIS Web Server, ASP.Net, C,
Microsoft Visual studio 2003 Web Service, Web
Reference, WSDL compiler and XML Database - Common Standards SOAP, HTTP, XML WSDL
5Modules
- Java Application
- .Net Application
- Web Services
6Java Application(Laptops Online)
- Components
- Uses MVC Model
- Displays list of products
- Shopping cart
- Customer and Billing information
- Confirm order by email
- Access .Net web service to show shipment status
7Java Application Architecture
8.Net Application(Shipment tracking System)
- Components
- View Records
- Insert/updates the shipping status information
- Search for Current status
- Generates planned route and sends it to customer
email - Search for route with timestamp
- Receives new records by accessing Java web
service
9.Net Application Architecture
10Web Services
- 1. Network accessible programs
- 2. Expose functionality by receiving/sending
SOAP messages over HTTP/HTTPS, - 3. Describe interface as WSDL descriptions.
- WSDL is the description language for Web services
- WSDL is an XML-based language for describing Web
services and how to access them. - A WSDL document describes
- What the service can do
- Where it resides
- How to invoke it
-
11WSDL Document Structure
WSDL doc
lttypesgt
ltmessagesgt
ltporttypesgt
ltbindingsgt
ltservicesgt
12A request-response operation example
- ltmessage name"getTermRequest"gt
- ltpart name"term" type"xsstring"/gt
- lt/messagegt
- ltmessage name"getTermResponse"gt
- ltpart name"value" type"xsinteger"/gt
- lt/messagegt
- ltportType name"glossaryTerms"gt ltoperation
name"getTerm"gt ltinput message"getTermReque
st"/gt ltoutput message"getTermResponse"/gt
lt/operationgtlt/portTypegt - ltbinding type"glossaryTerms" name"b1"gt
- ltsoapbinding stylerpc transport"http//sche
mas.xmlsoap.org/soap/http" /gt ltoperationgt - ltsoapoperation soapAction"http//example
.com/getTerm"/gt - ltinputgt
- ltsoapbody use"literal"/gt
- lt/inputgt
- ltoutputgt
- ltsoapbody use"literal"/gt
- lt/outputgt
- lt/operationgt
- lt/bindinggt
13App2App Interaction Web Services
- Transport protocol
- HTTP/HTTPS
- Data Encoding
- SOAP (Simple Object Access Protocol)
- Interface Description
- WSDL (Web Services Description Language)
14Architecture
15Creating Java Web Service
- Create an interface and an implementation class
- Java2WSDL Generate the WSDL file for the given
java web service interface. - WSDL2Java Generate the server side wrapper code,
and stubs for client access. - JavawebservSoapBindingImpl Fill in wrapper to
call the existing code. - Deploy Deploy the service to Apache Axis.
- Client Write a client that uses the generated
stubs, to access the Web service.
16Creating .Net Web Service
- .Net Web Service can be created using Microsoft
Visual Studio .Net 2003 software. - In the File menu select Add new item and select
the web service option and define the web methods
to access the data.
17Consuming Java web service from .Net application
- In the visual studio software, in the Project
menu select Add web reference option - In the url box enter the wsdl file path of the
java web service for example http//localhost812
3/axis/services/laptop.wsdl - When the url is entered it gives the list of
methods in the service eg getOrderId,
getLocation etc - Click Add web reference and your web service is
ready to be accessed - To access this web service a proxy client is
created. For that we need the wsdl file of that
particular web service - Use the WSDL compiler of the .net framework to
generate the cs file. - Now add this cs file, which is the proxy class
for the referenced web service to your .Net
application. - By making the instance to this proxy client we
can call the Java web service
18Consuming .Net web service from Java application
- Create a .Net web service (Service.asmx)
- Use WSDL2Java tool to generate the server side
wrapper code, and stubs for client access. - gtjava WSDL2Java Service.asmx?WSDL
- Write a java client that uses the generated
stubs, to access the Web service. - By making the instance to this proxy client we
can call the .Net webservice. - And data can be accessed and displayed.
19Demo Scenario
20Demo Shipment Locations(15 US major cities)
21Future Work
- Service Description and Discovery
- UDDI (Universal Description, Discovery and
Integration) - Security
- WS-Security, XML-Signature, XML-Encryption, ...
22Thank You