1 / 12

CIS 375—Web App Dev II

CIS 375—Web App Dev II. WSDL. Introduction toWSDL. WSDL stands for Web __________ Description Language WSDL is written in ______ WSDL is an XML document A WSDL document specifies the location of a Web service and the operations the service exposes. WSDL is not yet a W3C standard.

Download Presentation

CIS 375—Web App Dev II

An Image/Link below is provided (as is) to download presentation Download Policy: Content on the Website is provided to you AS IS for your information and personal use and may not be sold / licensed / shared on other websites without getting consent from its author. Content is provided to you AS IS for your information and personal use only. Download presentation by click this link. While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server. During download, if you can't get a presentation, the file might be deleted by the publisher.

E N D

Presentation Transcript


  1. CIS 375—Web App Dev II WSDL

  2. Introduction toWSDL • WSDL stands for Web __________ Description Language • WSDL is written in ______ • WSDL is an XML document • A WSDL document specifies the location of a Web service and the operations the service exposes. • WSDL is not yet a W3C standard

  3. WSDL Documents • A WSDL document is just a simple _____ document. • A WSDL document defines a web service using these major elements: • <portType> The ________ performed by the web service • <message> The messages used by the web service • <types> The data types used by the web service • <binding> The communication ________ used by the web service • Structure of a WSDL document: <definitions> <types> definition of types........ </types> <message> definition of a message.... </message> <portType> definition of a port....... </portType> <binding> definition of a binding.... </binding> </definitions>

  4. WSDL Elements (1) • WSDL Ports • The <portType> element is the most important. • It defines a web service, the operations that can be performed, and the messages that are involved. • The <portType> element can be compared to a ________ library (a module, a class) in a programming language. • WSDL Messages • The <message> element defines the _____ elements of an operation. • Each message can consist of one or more parts. • The parts can be compared to the ___________ of a function call in a programming language.

  5. WSDL Elements (2) • WSDL Types • The <types> element defines the data type that are used by the web service. • For maximum platform neutrality, WSDL uses XML _______ syntax to define data types. • WSDL Bindings • The <binding> element defines the message format and _________ details for each port.

  6. WSDL Example <message name="getTermRequest"> <part name="term" type="xs:string"/> </message> <message name="getTermResponse"> <part name="value" type="xs:string"/> </message> <portType name="glossaryTerms"> <operation name="getTerm"> <input message="getTermRequest"/> <output message="getTermResponse"/> </operation> </portType> • Compared to traditional programming, “glossaryTerms” is a function ________, “getTerm” is a ________ with “getTermRequest” as the _______ parameter and “getTermResponse” as the return parameter.

  7. WSDL Ports • A WSDL port describes the __________ (legal operations) exposed by a web service. • Operation Types • One-way: The operation can receive a message but will not return a response • Request-response: The operation can receive a request and will return a response • Solicit-response: The operation can send a request and will wait for a response • Notification: The operation can send a message but will not wait for a response

  8. One-Way Operation <message name="newTermValues"> <part name="term" type="xs:string"/> <part name="value" type="xs:string"/> </message> <portType name="glossaryTerms"> <operation name="setTerm"> <input name="newTerm" message="newTermValues"/> </operation> </portType > • The port "glossaryTerms" defines a one-way operation called "setTerm". • The "setTerm" operation allows input of new glossary term messages using a "newTermValues" message with the input parameters "term" and "value". • However, no _______ is defined for the operation.

  9. Request-Response Operation <message name="getTermRequest"> <part name="term" type="xs:string"/> </message> <message name="getTermResponse"> <part name="value" type="xs:string"/> </message> <portType name="glossaryTerms"> <operation name="getTerm"> <input message="getTermRequest"/> <output message="getTermResponse"/> </operation> </portType> • The port "glossaryTerms" defines a request-response operation called "getTerm". • The "getTerm" operation requires an ______ message called "getTermRequest" with a parameter called "term“. • It will return an _______ message called "getTermResponse" with a parameter called "value".

  10. WSDL Bindings <binding type="glossaryTerms" name="b1"> <soap:binding style="document" transport="http://schemas.xmlsoap.org/soap/http" /> <operation> <soap:operation SoapAction="http://example.com/getTerm"/> <input> <soap:body use="literal"/> </input> <output> <soap:body use="literal"/> </output> </operation> </binding> • The binding element has two attributes. • The name attribute can be anything you want. • The type attribute points to the port for the binding. • The soap:binding element has two attributes. • The style attribute can be "rpc" or "document". • The transport attribute defines the SOAP protocol to use. • The operation element defines each operation. • For each operation the corresponding SOAP action is defined. • You must also specify how the input and output are encoded. In this case we use "literal".

  11. WSDL and UDDI • UDDI is a platform-independent framework for describing services, discovering businesses, and integrating business services by using the Internet. • UDDI: Universal Description, Discovery and ___________ • UDDI is a directory for storing info about web services • UDDI is a directory of web service interfaces • UDDI communicates via ______ • UDDI is built into the Microsoft _____ platform • UDDI is a cross-industry effort driven by all major platform and software providers and e-business leaders.

  12. Some WSDL Tutorials • Site with many WSDL tutorials • WSDL learning guide • A Busy Developer's Guide to WSDL 1.1 • WSDL client tutorial • Hello World Tutorial

More Related