Saturday, 20 February 2016

SOA Interview Questions : Service Oriented Architecture Interview Questions Part 3

What is WSDL ?

The Web Services Description Language (WSDL) is an XML-based interface definition language that is used for describing the functionality offered by a web service. The WSDL provides a machine-readable description of how the service can be called, what parameters it expects, and what data structures it returns.

Can you write a sample WSDL ?

<?xml version="1.0" encoding="UTF-8" ?>
<definitions targetNamespace="tns:https://www.DemoService.test" xmlns=""
             xmlns:tns="tns:https://www.DemoService.test" xmlns:soap12=""
             xmlns:mime="" xmlns:xsd=""

<!-- Abstract type -->
    <xsd:schema targetNamespace="tns:https://www.DemoService.test/types" elementFormDefault="qualified"/>

<!-- Abstract Message -->
  <message name="NewMessage">
    <part name="in" element="xsd:any"/>
  <message name="NewReturnMessage">
    <part name="return" element="xsd:any"/>

<!-- Abstract Port Type -->
  <portType name="DemoServicePortType">
    <operation name="NewOperation">
      <input message="tns:NewMessage"/>
      <output message="tns:NewReturnMessage"/>

<!-- Concrete Binding with SOAP-->
  <binding name="DemoServiceBinding" type="tns:DemoServicePortType">
    <soap:binding style="document" transport=""/>
    <operation name="NewOperation">
      <soap:operation style="document" soapAction="tns:https://www.DemoService.test/NewOperation"/>
        <soap:body use="literal" parts="in"/>
        <soap:body use="literal" parts="return"/>

<!-- Concrete Service location-->
  <service name="DemoService">
    <port name="DemoServicePort" binding="tns:DemoServiceBinding">
      <soap:address location=""/>


How are different Elements of WSDL related ?

This can be understood by below representation

Explain different versions of WSDL standards ?

The current version of the specification is 2.0; version 1.1 has not been endorsed by the W3C but version 2.0 is a W3C recommendation.

Explain elements/tags of WSDL ?

WSDL 1.1 Term
WSDL 2.0 Term
Contains a set of system functions that have been exposed to the Web-based protocols.
Defines the address or connection point to a Web service. It is typically represented by a simple HTTP URL string.
Specifies the interface and defines the SOAP binding style (RPC/Document) and transport (SOAP Protocol). The binding section also defines the operations.
Defines a Web service, the operations that can be performed, and the messages that are used to perform the operation.
Defines the SOAP actions and the way the message is encoded, for example, "literal." An operation is like a method or function call in a traditional programming language.
Typically, a message corresponds to an operation. The message contains the information needed to perform the operation. Each message is made up of one or more logical parts. Each part is associated with a message-typing attribute. The message name attribute provides a unique name among all messages. The part name attribute provides a unique name among all the parts of the enclosing message.
Messages were removed in WSDL 2.0, in which XMLschema types for defining bodies of inputs, outputs and faults are referred to simply and directly.
Describes the data. The XML Schema language (also known as XSD) is used (inline or referenced) for this purpose.

What are  different types of WSDL ?
There are two types of WSDL
1.       Concrete WSDL
Abstract WSDL 

Can you define types of  WSDL ?

 Abstract WSDL contains only Types, Messages and Operations. Abstract WSDL is used by server side components programming.

Concrete WSDL contains all elements of WSDL, such as Types, Messages, Operations , Binding and Service transport specific information (JMS or Http). This is used by client side components. 

Refer Previous post on Interview questions at

1. SOA Interview Questions : Service Oriented Architecture Interview Questions Part 1

2. SOA Interview Questions : Service Oriented Architecture Interview Questions Part 2

No comments:

Post a Comment