What are Web Services?

7 downloads 284 Views 4MB Size Report
Jun 29, 2001 ... Michael Papazoglou. • Can be found, mixed and matched to create complete business processes. – Enables dynamic integration with ...
THE WEBWEB-SERVICES PHENOMENON: Concepts Technologies Trends & Research Directions Prof. dr. ir. Mike P. Papazoglou INFOLAB, Tilburg University, The Netherlands email: [email protected] http://infolab.kub.nl/people/mikep © Prof. dr. ir. Michael Papazoglou. Page: 1

AGENDA ? Introduction: webweb-service definitions & examples ? Characteristics & types of webweb-services ? e-Marketplaces & B2B integration examples ? Service Service--oriented architecture ? WebWeb-services framework: ? WSDL ? UDDI ? WSFL ? ebXML ? Research directions © Prof. dr. ir. Michael Papazoglou. Page: 2

•1

© Prof. dr. ir. Michael Papazoglou. Page: 3

Challenges

“Part of the problem is that even at this early stage, Web services have more faces than Fu Manchu. . . . Inevitably, companies involved with Web services will define them in their own way. The term Web services will be a messy catchall phrase.” Intelligent Enterprise, Enterprise June 29, 2001

© Prof. dr. ir. Michael Papazoglou. Page: 4

•2

The road to Web Services XML HTML

gy P nolo h TCP/I c Te

Connectivity Presentation

Inn ova FTP, E-mail tion

Web P ages

Browse the Web

Programmability

Web Serv ices Program the Web © Prof. dr. ir. Michael Papazoglou. Page: 5

What are Web Services? ?A web service is programmatically available application logic exposed over the Internet ?Web services perform encapsulated business functions that can range from simple requestrequest-reply to full business process interactions ?Web services apply web technologies such as HTTP and XML to the concepts of distributed computing technologies such as CORBA and DCOM ?Examples of web services: –currency conversion –stock quotes/stock charting –credit card verification/payment processing –integrated travel planning © Prof. dr. ir. Michael Papazoglou. Page: 6

•3

What are Web Services? • Can be found, mixed and matched to create complete business processes. – Enables dynamic integration with decreased human interaction – Both new & extensions to existing applications • Enables Enables information to be queried, updated in realrealtime • Available to a variety of clients (platform independent), e.g. stock quote, weather, and authentication services ? on “pay per use”, “lease it”, “pay for it” basis. © Prof. dr. ir. Michael Papazoglou. Page: 7

What ís wrong with how we build Distributed Applications? Applications? • CORBA / EJBs / DCOM don’t talk to each other

•Different vendors, different dialects (incompatible) •Heterogeneous data representations •Hard coded business process •Hard to extend applications beyond their original scope •Not easily discoverable / usable

© Prof. dr. ir. Michael Papazoglou. Page: 8

•4

Consumer & Provider Perspectives What does it do?

How it does it (business requs) How to build it Interface

How do I use it? Where can I find it? Client Perspective

Implementation

How to publish it

Where to host it

Provider Perspective © Prof. dr. ir. Michael Papazoglou. Page: 9

A travel planning application using webweb-services

2. The travel agent Web server, linked via web-services to the servers of these sites, forwards the requests.

Name No. Zip State OK Cancel

1. Customer visits travel agent Web site & makes request to buy an airline ticket, rent a car & reserve a hotel room.

Name No. Zip State OK

Cancel

4. Customer receives trip confirmation after a visit to a single Web site.

3. The airline, car rental & hotel servers receive the requests & return XML confirmations to the travel agent Web server.

© Prof. dr. ir. Michael Papazoglou. Page: 10

•5

Weather service

Flight Reservation Service

Travel service Inc. Hotel Reservation

find

Weather at destination

find

Car Rental

find

Flight reservation

find

Car Rental Service Hotel Reservation Service © Prof. dr. ir. Michael Papazoglou. Page: 11

Accessing webweb-services over the Internet

Web-service definitions-interface

Web-service access

Web-service programming environment Web-service client

Servers Web-service provider

© Prof. dr. ir. Michael Papazoglou. Page: 12

•6

Are ASP, Software as a Service, Web Service the same? Customer

App. solution provider

Name No. Zip

Name No.

State OK

Cancel

View in Browser

Zip State OK

Typical ASP Today

Cancel

Name Name No. Zip State OK

No. Zip

Download on Demand

State OK

Cancel

Cancel

Software as a Service

Name No. Zip

Access Service

State OK

Cancel

Web Service source: CBDi forum

© Prof. dr. ir. Michael Papazoglou. Page: 13

Web services characteristics ?

Modular by design, web services are inherently interface oriented allow easy plug-and-play

?

Loosely-coupled systems that connect and interact more freely.

?

Described using WSDL as a service description language.

?

Published using UDDI by making its description available to potential users.

?

Found using UDDI by sending queries to that registry and receiving the binding details of the service(s) that fit the parameters of the query.

?

Bound using SOAP by using the information contained in the service description to customize the connection.

?

Invoked using SOAP over a network by using the information contained in the binding details of the service description.

?

Composed using WSFL with other services into new services. © Prof. dr. ir. Michael Papazoglou. Page: 14

•7

Types of Web services Simple •informational services based on XML messaging ? example: credit card authorization, weather reports, stock quote info.

Complex trading services •document exchange / B2B based exchanges ? example: Procurement Business Process. ? Involves service conversation sequences.

© Prof. dr. ir. Michael Papazoglou. Page: 15

Examples of Web Services Business Information with rich content ? weather reports

? credit check

? news feed

? request for quote

? airline schedules

? Auction lists

? stock quotes

? inventory control

Transactional Web Services for B2B or B2C ? airline reservations

? supply chain management

? rental car agreements

? procurement

auctions

Business Process Externalisation ? business linkages at a workflow-level ? allows integration at a (business) process level ? within an enterprise & between partners © Prof. dr. ir. Michael Papazoglou. Page: 16

•8

Types of Programmatic Web Services • Remote Procedure Call (RPC)(RPC)-based for supporting simple Web Services Web Service Interface

Online Online order order request request

Online Online order order response response

Application programs or stored procedures

Database

© Prof. dr. ir. Michael Papazoglou. Page: 17

• DocumentDocument-based Web Services for supporting loosely coupled asynchronous models. Bulk Bulk Purchase Purchase Order Order

Web Service Interface

Receive e-mail acknowledgment

Database

Check Ship

Invoice Invoice

Send

Business Process Flow © Prof. dr. ir. Michael Papazoglou. Page: 18

•9

Remote Procedure Call (RPC)(RPC)based Web Services • Implemented using a stateless session EJB. • Appears as a remote object to the client application. • The interaction centers around a serviceservicespecific interface. • Resemble traditional distributed object paradigms, such as RMI. • Synchronous, meaning that when a client sends a request, it waits for a response before doing anything else. © Prof. dr. ir. Michael Papazoglou. Page: 19

DocumentDocument-Based Web Services • Loosely coupled and documentdocument-driven • Client invokes a messagemessage-based web service by sending it an entire document, such as a purchase order, rather than a discrete set of parameters. • The web service accepts the entire document, processes it, and may or may not return a result message. • Promotes a looser coupling between client and server and provide additional benefits beyond RPCRPC-based web services © Prof. dr. ir. Michael Papazoglou. Page: 20

•10

How can web services be used? ?

Between businesses ? Providing service to your customers –

e.g., How long & how much does it cost an Insurance company to link its systems to the systems of a new institutional customer?

? Accessing services from your partners and suppliers –

– – –

?

e.g., Dynamically link to new partners and suppliers to offer their services to complement the value you provide

Standards and common infrastructure reduce the barriers Simplicity accelerates deployment Dynamics opens new business opportunities

Within a business ? ? ? ?

Accelerate and reduce the cost of integration Save on infrastructure deployment & mgt costs Reduce skill requirements Improve reuse

Web Services © Prof. dr. ir. Michael Papazoglou. Page: 21

Web Services Can Support Simple & Syndicated Processes Customer Discover Supplier

Registry

UDDI

Supplier

3rd Party

Publish Supplier Service

Check Availability and Price Place Order Check Credit

CityBank

Confirm Order Create Shipping Manifest Confirm Shipment

UPS

© Prof. dr. ir. Michael Papazoglou. Page: 22

•11

What Problems Do We Solve? A midmid-sized manufacturer needs to create 500 online relationships with customers, each with their own set of standard and protocols

Broader B2B

A flower shop in Australia wants to be “plugged in” in” to every marketplace in the world, but doesn’ doesn’t know how

More “Intelligent” Intelligent” Search

A B2B marketplace can get catalog data for relevant suppliers in its industry, along with connections to shippers, insurers, etc.

Easier Aggregation

Describe Services Discover Services Integrate them together

© Prof. dr. ir. Michael Papazoglou. Page: 23

e-Marketplace:Vertical WebWeb-services Travel E-Service Customer Information E-Service

Restaurant reservation E-Service

Business Business Model Model Customer Customer Knowledge Knowledge

Weather E-Service

e-Marketplace

Product Product Knowledge Knowledge

Common business terminology

Reservation E-Service

Airline booking E-Service

Hotel booking E-Service

© Prof. dr. ir. Michael Papazoglou. Page: 24

•12

Web Services Requests and Responses User Interfaces

Internal Systems

B2B

Response Out

Request In Web Service

Content

Web Sites

ERP

Relational Databases

Packaged Applications

Legacy Applications

© Prof. dr. ir. Michael Papazoglou. Page: 25

Example B2B Process Integration “We’ve got 18 now and are expecting 50 more by Friday.”

Supplier “How many widgets do you have on hand?”

Web Service ? Receive request document ? Evaluate request ? Transform data

Customer

? Route document

? Receive document ? Map data to target ? Map answer to response document ? Return response document

© Prof. dr. ir. Michael Papazoglou. Page: 26

•13

Web Services Interface & Realization Imported web-service interfaces

Web-service specification

Web-service usage interface Web-service client

build/rent reuse/lease

Service-realization

build

Web-service Implementation (in-house)

Web-service Implementation (outsourced)

Web-service Implementation (outsourced)

© Prof. dr. ir. Michael Papazoglou. Page: 27

Foundation for Web Services Compose, combine Services:WSFL Services:WSFL Publish, Find, Use Services: UDDI Formal Service Descriptions: WSDL Service Interactions:

SOAP

Universal Data Format:

XML

Ubiquitous Communications: Internet Simple, Open, Broad Industry Support © Prof. dr. ir. Michael Papazoglou. Page: 28

•14

ServiceService-oriented Architecture Service Description

Service Provider

Bind SOAP

Publish (WSDL, UDDI)

Service Registry Service Description

Find

Service Requester

(WSDL, UDDI)

© Prof. dr. ir. Michael Papazoglou. Page: 29

Web Services Description Language • WSDL is a simple XML grammar, similar in purpose to IDL, describing Web service capabilities & how to communicate with a Web service – It defines the messages (both abstract and concrete) that are sent to and received from a service – It defines logical collections of messages (“port type”, “interface”) – It defines how a given “port type” is bound to particular wire protocols – It defines where the service is located © Prof. dr. ir. Michael Papazoglou. Page: 30

•15

WSDL Document Structure ? - Root element ? - Provides data type definitions ? - Represents the abstract definition of the data being transmitted ? - Defines a set of abstract operations ? - Specifies concrete protocol and data format specifications for the operations and messages defined by a particular portType ? - Specifies an address for a binding ? - Used to aggregate a set of related ports.

© Prof. dr. ir. Michael Papazoglou. Page: 31

WSDL - Overview >

Definition Definitionof ofdata datatypes types Definition Definitionof ofmessages messages Definition Definitionof ofport porttype type Definition Definitionof ofthe thebindings bindings



Definition Definitionof ofthe theservice service



© Prof. dr. ir. Michael Papazoglou. Page: 32

•16

Message • A message is protocol independent • There is an input or request message, which is sent from the client to the service, and there is a output or response message, which is sent back the opposite way • Each element contains one or more elements. • element corresponds to the parameter or a return value in the RPC call. • The part name order reflects the order of the parameters in the RPC signature.

© Prof. dr. ir. Michael Papazoglou. Page: 33

Message contd. >

>

© Prof. dr. ir. Michael Papazoglou. Page: 34

•17

Operations and PortType • Operation defines which message is the input and which message is the output • A collection of all operations exposed bythe web service is called a portType >

© Prof. dr. ir. Michael Papazoglou. Page: 35

Operations and PortType • WSDL has four transmission primitives that an endpoint can support: ? One One--Way – The endpoint receives a message ? Request Request--response – The endpoint receives a message and sends a correlated message ,, ? SolicitSolicit-response – The endpoint sends a message and receives a correlated message , , ? Notification – The endpoint sends a message © Prof. dr. ir. Michael Papazoglou. Page: 36

•18

Binding • Binding mechanism is used to attach a specific protocol, data format or structure to an abstract message , operation or endpoint • Binding MUST specify exactly one protocol • Binding MUST NOT specify address information • Extensibility elements are commonly used to specify some technology specific binding …

© Prof. dr. ir. Michael Papazoglou. Page: 37

Port • A port defines an individual endpoint by specifying a single address address for a binding > > address location="http://www.stocks.com/services/ location="http://www.stocks.com/services/stockquote stockquote "/> > :documentation> Returns last trade stock price
binding "StockQuoteServiceSOAPBinding "StockQuoteServiceSOAPBinding" " ---> >

name="StockQuoteServicePort name=" StockQuoteServicePort" " binding="tns binding=" tns: :StockQuoteServiceSOAPBinding StockQuoteServiceSOAPBinding"> ">

->

© Prof. dr. ir. Michael Papazoglou. Page: 39

UDDI Overview • UDDI is: – An XMLXML-based platform that offers public descriptions of available webweb-services behaviour, behaviour, binding & communication protocols – A Web Services API for publishing and discovering the existence of Web services – A registry for managing information about Web services – UDDI registries may either belong to private eemarketplaces or be internal to an enterprise. – A coalition of organisations working together to manage UDDI registries and to further develop the Web Services API for accessing those registries. © Prof. dr. ir. Michael Papazoglou. Page: 40

•20

UDDI Overview • UDDI is built around “YellowYellow- pages”like data model: businessEntity: Information about the businessEntity: Information about the party who publishes information about a party who publishes information about a family of services. family of services.

tModel: Descriptions of specifications Descriptions of specifications fortModel: services or taxonomies. Basis for for services or taxonomies. Basis for technical fingerprints. technical fingerprints.

businessService: Descriptive businessService: Descriptive information about a particular information about a particular service. service.

PublisherInsertion: Information PublisherInsertion: Information about a relationship between two about a relationship between two parties, asserted by one or both. parties, asserted by one or both.

bindingTemplate: Technical bindingTemplate: Technical information about a service entry information about a service entry point and construction point and construction specifications. specifications.

bindingTemplate data contains references to tModels. These references designate the interface specifications for a service.

© Prof. dr. ir. Michael Papazoglou. Page: 41

Universal Description, Discovery & Integration (UDDI) Registry Entries

?

Entities register published information about themselves

?

Standards Bodies, Publishers register information about their Service Types (specs) © Prof. dr. ir. Michael Papazoglou. Page: 42

•21

• Business name • General business description – Any number of languages • Contact info – Names, phone numbers, fax numbers, web sites, etc. • Known identifiers – List of unique identifiers for a business domain name, stock ticker symbol, etc. © Prof. dr. ir. Michael Papazoglou. Page: 43

• Classification by a standard index of business & industries (Business categories). – 3 standard taxonomies in Version1: • Industry: NAICS (Industry classification system) • Product/Services: Universal standard products & services classification • Location: Geographical taxonomy (ISO 3166)

© Prof. dr. ir. Michael Papazoglou. Page: 44

•22

• Set of technical info. & services that businesses use to describe how to “do ee-business” with them – Nested model, where: A business entity contains business services which contain binding templates. e.g., a company (business entity) advertises that it can: ? accept orders, shipping notices & invoices electronically, & provide online inventory searches for regular customers; ? these can support several protocols or specs (EDI standards, XML vocabularies, etc) each protocol/spec. having a separate binding template.

– Programming/platform implementation agnostic. © Prof. dr. ir. Michael Papazoglou. Page: 45

• TModel = “Technology Model”

TModel

TModel Instance

Abstract metadata definition relating to some aspect of the UDDI registration

Implementation specific metadata conforming to a given TModel.

TModel = Abstract Class

© Prof. dr. ir. Michael Papazoglou. Page: 46

•23

• TModels – Categories & Identifiers • Categorization and Identification taxonomies are TModels • Categories and Identifiers are TModel Instances • Keyed Referenced – Name + Value + TModel

• Examples: NAICS, UNSPSC, D&B #

– WSDL Port Types • WSDL Port Types are TModels • WSDL Services that are bound to a Port Type are TModel Instances

– WSFL Business Processes • WSFL Flow Models are TModels • WSFL Global Models are TModel instances TModels represent the extent of UDDI’ s semantic description capabilities.

© Prof. dr. ir. Michael Papazoglou. Page: 47

How UDDI Works 1.

Software companies, standards bodies, and developers populate the registry with descriptions (specifications) of types of services

4.

Marketplaces, search engines, and business applications query the registry to discover services at other companies

UDDI Registry

2.

Businesses populate the registry with descriptions of the services they support

Business Registrations

3.

Service Type Registrations

5.

UDDI Registry assigns a programmatically unique identifier to each service and business registration Business uses this data to facilitate easier integration with each other over the Web © Prof. dr. ir. Michael Papazoglou. Page: 48

•24

UDDI Registry WSDL Service Implementation . . . . . . . . < overviewURL> http://...#StockQuoteServiceBing . . . .

WSDL Service Interface