410 likes | 427 Views
This math thesis presentation explores the use of interface automata and parameterized interface automata to model and discover web services. It discusses the motivations behind component-based design and the need for formal modeling. The presentation also introduces interface automata and their operations of composition and refinement. Additionally, it proposes a new model, parameterized interface automata, to handle complex actions in web service composition.
E N D
An Interface-Based Approach to Discovery and Composition of Web Services M.Math Thesis Presentation Shahram Esmaeilsabzali 11 June,2004
Outline • Interface Automata • Parameterized Interface Automata • Web services and Interface Models • Stateless Interfaces • Satisfiability Relation
Motivation • Component-based design is becoming a prevalent paradigm for software development • Components are meant to provide: • Functionality without implementation details • Reusable software artifacts • Interoperable software artifacts • As such, appropriate formalisms can be used to model components
Motivation Cont’d • Components usually expose their functionalities through their interfaces • Components can invoke other components’ methods • Often there are some valid orders of execution for methods of a component • Components may communicate through messagepassing
Interface Automata (IA) • Interface automata are suitable models for modeling component-based systems prod_id prod_name in_us cnd$_price! prod_id? prod_name? in_us? us$_price! us$_price cnd$_price
Example prod_id prod_name in_us cnd$_price credit_no us$_price cnd$_price! prod_id? ref_no! credit_no? cnd$_price? prod_name? err_no! us$_price! in_us? ref_no err_no cnd$_price us$_price
Example prod_id prod_name in_us cnd$_price credit_no us$_price cnd$_price! prod_id? ref_no! credit_no? cnd$_price? prod_name? err_no! us$_price! in_us? err_no ref_no cnd$_price us_price prod_name credit_no in_us prod_id prod_id? ref_no! credit_no? prod_name? cnd$_price; prod_id? credit_no? prod_name? err_no! err_no ref_no
IA Cont’d • IA is a model introduced by Luca De Alfaro and Thomas A. Henzinger for modeling component-basedsystems • IA is an interface model, with two key operations: • Composition: Commutative and associative operation mapping two IAs to one IA • Refinement: Checks similarity between two IAs
IA is an interface Model • Interface models are concise models which: • Rely on helpful environments (are optimistic models) • Support composition and refinement • Support top-down design • f || g and f’refines f, then (f’ ||g)refines(f || g) • IAs are statefulinterface models
IA Composition prod_id prod_name in_us credit_no us$_price cnd$_price cnd$_price! prod_id? ref_no! credit_no? cnd$_price? prod_name? err_no! us$_price! in_us? err_no ref_no cnd$_price us$_price
IA Composition- Cont’d prod_id in_us prod_name credit_no credit_no? in_us? credit_no? in_us? prod_id? ref_no! prod_name? cnd$_price; prod_id? credit_no? prod_name? err_no! prod_name? in_us? prod_id? err_no! ref_no! credit_no? ref_no! err_no! err_no! ref_no! in_us? prod_name? prod_id? err_no ref_no
IA Cont’d (helpful environment) prod_name credit_no in_us prod_id in_us? credit_no? credit_no? prod_id? ref_no! in_us? prod_name? cnd$_price; prod_id? credit_no? prod_name? err_no! err_no ref_no Environment ref_no err_no prod_name! credit_no! ref_no? err_no? in_us prod_id credit_no
IA Refinement credit_no us$_price cnd$_price ref_no! Pay credit_no? cnd$_price? err_no! ref_no err_no cnd$_price account_no credit_no us$_price credit_no? ref_no! cnd$_price? GenPay account_no? ref_no
IA is not descriptive enough • Actions in IA are atomic elements • Software methods/messages/functions are all complex elements consisting of atomic elements • To provide such complex elements we propose a new model
Parameterized Interface Automata (PIA) credit_no us$_price cnd$_price ref_no! pay_in_cnd credit_no? cnd$_price? err_no! ref_no err_no
PIA Cont’d • Each complex action either consists entirely of input/internal or output/internal actions • Each complex action maintains the sequentiality of its consisting simple elements during compositions
PIA Composition prod_id prod_name in_us credit_no us$_price cnd$_price pay_in_cnd cnd$_price! prod_id? ref_no! cnd$_price? credit_no? err_no! us$_price! in_us? prod_name? ref_no err_no cnd$_price us$_price prod_name credit_no in_us prod_id pay_in_cnd prod_id? ref_no! credit_no? prod_name? cnd$_price; err_no! ref_no err_no
PIA Composition- Cont’d prod_id prod_name credit_no in_us credit_no? in_us? pay_in_cnd credit_no? prod_id? ref_no! prod_name? cnd$_price; credit_no? err_no! prod_id? in_us? prod_name? err_no! ref_no! credit_no? ref_no! err_no! err_no! ref_no! in_us? prod_name? prod_id? err_no ref_no
PIA vs. IA prod_name credit_no in_us prod_id pay_in_cnd prod_id? ref_no! credit_no? prod_name? cnd$_price; err_no! ref_no err_no prod_name credit_no in_us prod_id prod_id? ref_no! credit_no? prod_name? cnd$_price; prod_id? credit_no? prod_name? err_no! err_no ref_no
PIA Refinement credit_no us$_price cnd$_price ref_no! pay_in_cnd Pay credit_no? cnd$_price? err_no! ref_no err_no credit_no us$_price cnd$_price account_no pay_in_cnd ref_no! credit_no? cnd$_price? account_no? GenPay cnd$_price? err_no! pay_in_cnd_acc ref_no err_no
Web Services • Web service is a distributed component model over internet which operates using some standards/formats Web Services Flow Language (BPEL4WS, OWL-S, … ) Universal Description, Discovery and Integration (UDDI) Web Services Description Language (WSDL) Simple Object Access Protocol (SOAP) XML Common Internet Protocols (TCP/IP, HTTP, … )
Web Services • AtomicWeb services can be defined by their input and outputmessages and the orderof those messages • CompositeWeb services consist of a set of atomic Web services which are glued through: • Workflows (sequence, choice, parallel,…) • Data flows (specifying the destination of messages)
Web services and PIAs • Different workflow patterns can be simulated by PIAs • Data flows can be expressed through internal actions • Web services can exchange composite XML messages and PIAs can model those messages
Web services Discovery • Web services are meant to be published and discovered by interested parties. • How can interested parties search for their desired Web services? • The search request should be specified in an appropriate level of abstraction • Search requests should somehow be compared against the Web services
Stateless interfaces • Statelessinterfaces do not specify the orderof events in a system • They are smaller models than stateful interfaces • Useful for specifying search requests in a Web service discovery system
Multiple Port Dependency Interface (MPD) a d b m e c
MPD Composition a d n m B A b m e c a d b A || B n e c
MPD Request prod_id cnd$_price prod_name us$_price in_us A service which receives a “product name” or a “product id” and provides the price of that product in Canadian Dollar.
Weak Interfaces • MPDs do not specify the order of dependency pairs • By defining “order” among dependency pairs, it is possible to specify some temporality • such partial specification of temporality is useful but makes composition non-associative • Weak interfacesdo not support associativity in composition • Enhanced port dependency interface (EPD) is a weak interface model
Enhanced Port Dependency Interface (EPD) 1 a d 2 b m 1 e c 2
EPD Composition 1 a d 2 b A 1 m m 1 B n e c 2 e 2 p a d 1 b A || B n p c 2
EPD Requests 1 prod_id cnd$_price prod_name 1 2 us$_price in_us A service which receives a product id and provides the price of that product in Canadian Dollar. Or, it receives a product id and then arequest for US price and returns the price in US Dollar.
Satisfiability Relations • Being able to specify search requests using MPD/EPD, we need a mechanism to compare requests against Web services • Satisfiability relations are defined between two interface classes and correlate instances of the two classes
Satisfiability between PIA and EPD ref_no prod_id 1 prod_name 2 err_no credit_no prod_name credit_no in_us prod_id pay_in_cnd prod_name? ref_no! credit_no? prod_id? cnd_price; err_no! ref_no err_no
Satisfiability Example ref_no prod_id 1 2 prod_name err_no credit_no prod_name credit_no in_us prod_id prod_id prod_name in_us credit_no us$_price cnd$_price pay_in_cnd prod_name? cnd$_price! ref_no! credit_no? prod_id? ref_no! credit_no? cnd$_price? prod_id? cnd_price; pay_in_cnd prod_name? err_no! us$_price! in_us? err_no! err_no ref_no cnd$_price us$_price ref_no err_no
ref_no prod_id 1 prod_name credit_no err_no in_us prod_name credit_no in_us prod_id pay_in_cnd prod_id? ref_no! credit_no? prod_name? cnd_price; err_no! ref_no err_no Satisfiability Example credit_no ref_no prod_id 1 cnd$_price us$_price prod_name 1 1 cnd$_price err_no 2 us$_price in_us credit_no us$_price cnd$_price prod_id prod_name in_us pay_in_cnd cnd$_price! prod_id? ref_no! cnd$_price? credit_no? us$_price! in_us? prod_name? err_no! ref_no err_no cnd$_price us$_price
Request Decomposition 1 1 prod_id prod_id cnd$_price cnd$_price cnd$_price 1 1 prod_name prod_name prod_id prod_name prod_name prod_id prod_id? cnd$_price! cnd$_price! cnd$_price! prod_id? prod_name? prod_name? cnd$_price cnd$_price cnd$_price
Semantic matching • Search request and Web services may use slightly different vocabularies for inputs and outputs. Semantic matching can be helpful in this respect. ISBN ref_no 1 2 book_name err_no credit_no prod_name prod_id credit_no in_us pay_in_cnd ref_no! credit_no? prod_id? cnd_price; prod_name? err_no! ref_no err_no
Future Works • Behavioral satisfaction (pre-conditions and post-conditions) • Useful decomposition techniques for interface models • Smart composition algorithm for satisfying search requests • Satisfiability relation/algorithm which uses complex actions as well as simple action • Semantic matching of messages