Click here to load reader

Introduction to Web Services - · PDF file Java API for XML Web Services (JAX-WS) ! RESTful Web Services ! Java API for RESTful Web Services (JAX-RS) 2. Introduction to Service-Oriented

  • View

  • Download

Embed Size (px)

Text of Introduction to Web Services - · PDF file Java API for XML Web Services (JAX-WS) ! RESTful...

  • Introduction to Web Services

    Held as part of the lecture series on

    Web Engineering at Vienna University of Technology

    May 2014

  • Business Informatics Group Institute of Software Technology and Interactive Systems 
 Vienna University of Technology Favoritenstraße 9-11/188-3, 1040 Vienna, Austria
 phone: +43 (1) 58801-18804 (secretary), fax: +43 (1) 58801-18896
 [email protected],

    Web Engineering Web Services

    Philipp Liegl

  • Outline of today’s talk

    ▪ Introduction to Service-Oriented Computing !

    ▪ SOAP !

    ▪ WSDL !

    ▪ UDDI !

    ▪ Java API for XML Web Services (JAX-WS) !

    ▪ RESTful Web Services !

    ▪ Java API for RESTful Web Services (JAX-RS)


  • Introduction to Service-Oriented Computing


    Context of Web Services: Distributed Information Systems

    ▪ Layers of an information system ▪ Presentation layer

    ▪ Communication interface to external entities ▪ Graphical user interface for human users 

    or non graphical user interface for 
 other programs

    ▪ Application logic layer ▪ Implements operations requested by clients

    through the presentation layer ▪ Resource management layer

    ▪ Deals with different data sources of an
 information system

    ▪ Distributed systems are split up into parts ▪ Run simultaneously on multiple computers ▪ Communicate over a network

    presentation layer

    application logic layer

    resource management layer


    TU W

    IE N

    W E

    In fo

    rm at

    io n

    S ys

    te m

  • Machine to machine communication Getting applications to talk to each other

    presentation layer

    application logic layer

    resource management layer


    TU W

    IE N

    W E

    In fo

    rm at

    io n

    S ys

    te m

    application logic layer

    resource management layerA

    n ot

    h er

    in fo

    rm at

    io n

    s ys

    te m


    presentation layer

    application logic layer


  • Introduction to Service Oriented Computing


    Tag Cloud

    What is a service?

  • Introduction to Service-Oriented Computing


    Heterogeneity as the main obstacle for seamless communication of distributed information systems

    Windows Server 2008 UNIX System

    Flight information and booking application

    (programmed in C)

    Travel information and booking application

    (programmed in Java)

    Travel agency "The agency" Airline "The airline"

    seamless interaction?

    • Mismatch in operating system, language, platform, etc. • Service-oriented computing is an emergent paradigm that helps to overcome

    these mismatches

    • Example: Yield management in the airline industry requires close system interaction in order to retrieve the most current prices

  • Introduction to Service-Oriented Computing


    Application integration using services

    Windows Server 2008 UNIX System

    Flight booking application (programmed in C)

    Flight information application

    (programmed in Java)

    Travel agency "The agency" Airline "The airline"

    • Service vs. Web Service • Services are business functions which an enterprise offers to its business

    partners • A possible implementation of Services are Web Services • However, other concepts may also be used to implement a Service, e.g.,


    Se rv

    ic e

    Se rv

    ic eRequest


  • Introduction to Service-Oriented Computing


    Important terms in service-oriented computing

    • (Web) Services are self-contained modules that can be described, published, located, orchestrated, and programmed using XML-based technologies over a network !

    • Service providers are organizations that provide the service implementations, supply their service descriptions, and provide related technical and business support !

    • Service clients are end-users and organizations that use some service !

    • Service aggregators are organizations that consolidate multiple services into a new, single orchestrated service offering that is commonly known as business process. !

    • A service-oriented architecture (SOA) is a logical way of designing a software system to provide services to either end-user applications or to other services distributed in a network, via published and discoverable interfaces.

  • Introduction to Service-Oriented Computing


    Characteristics of Web Services (WS)

    • WS semantically encapsulate discrete functionality • A Web Service is a self contained software module that performs a single task (e.g.

    weather forecast by passing the zip-code as parameter) • WS share a contract

    • In order to allow interaction of services, a formal contract must be established, that defines the exact terms of an information exchange between a service client and a service provider

    • WS abstract underlying program logic • A service exposes a certain functionality to a client. How that functionality is achieved

    (e.g., which program language is used, or which database is used) remains invisible to the caller

    • WS are loosely coupled software modules • A service interface is defined in a neutral manner, independent of the underlying

    platform, operating system, or programming language • Due to their neutral interfaces, services are not hard-wired. Thus, a service may be easily

    exchanged by another service, without much implementation effort • WS are reusable

    • A service may be reused by multiple applications

  • Introduction to Service-Oriented Computing


    Characteristics of Web Services II (WS)

    • WS can be dynamically found and included in applications • A WS provides programmable access. Thus, a WS may be embedded in a

    remotely located application, i.e., a service may be composed. • Unlike Web Sites, Web Services are not targeted at human users • They are called by and exchange data with other software modules and

    applications. • WS are described in terms of a standard description language

    • Web Service Description Language (WSDL) and Web Application Description Language (WADL) describe functional service characteristics • Functional requirements: Requirements of the functionality which must be provided.

    (Functions, Data, Behavior, etc.) • Non-functional requirements: Requirements of the circumstances under which the

    functionality must be provided (e.g., reliability, performance, etc.) • WS are distributed over the Internet

    • WS make use of existing ubiquitous transport Internet protocols like HTTP • By relying on the same well-understood transport mechanism as Web Content,

    Web Services may leverage existing infrastructures and may cross corporate firewalls.

  • Introduction to Service Oriented Computing


    Functional vs. Non-Functional Service Characteristics

    • Functional Service Characteristics • Detail the operational characteristics that define the overall behavior of the

    service • How the service is invoked • The location where it is invoked • Syntax of exchanged messages, etc.

    • Typically a question of the system design ! • Non-Functional Service Characteristics

    • Concentrate on service quality attributes • Service metering and cost • Performance metrics such as response time • Security attributes, authorization, authentication, transactional integrity,

    scalability, etc. • Typically a question of the system architecture

  • Introduction to Service Oriented Computing


    Tight versus loose coupling

    Tight coupling Loose coupling

    Physical coupling Direct physical link required Physical intermediary

    Communication style Synchronous Asynchronous

    Interaction pattern OO-style navigation of complex object trees Data-Centric, Self-Contained messages

    Control of process logic Central control of process logic Distributed logic components

    Underlying platforms Homogeneous Heterogeneous

    Service discovery and binding Statically bound services Dynamically bound services

    Platform dependencies Strong OS and programming language dependency OS- and programming language independent

    • Coupling refers to the degree to which software components depend upon each other.


  • Introduction to Service-Oriented Computing


    Web Services

    ▪ Types of Web services ! ▪ SOAP/WSDL based

    ▪ Service interface is exposed through WSDL documents ▪ Message exchange using SOAP ▪ Client code may be generated from WSDL description !

    ▪ Representational State Transfer (REST) ▪ Easy way to communicate with Web Services ▪ Resources are identified by URIs and their state is manipulated through HTTP

    operations GET, POST, PUT, DELETE ▪ Rather a set of architectural principles, than a standard

  • Introduction to Service-Oriented Computing Characterizing Web Services - Integration scenarios

Search related