192 Gao & Chung Copyright © 2007, Idea Group Inc. Copying or distributing in print or electronic forms without written permis- sion of Idea Group Inc. is prohibited. Within one life cycle of one transaction, if one canceling occurs at one of the three phrases (C, M, F), it can be expressed by equation 3. Here we call the semantic consistency of T1 the rst layer of semantic consistency within the Web-services conversation, and the semantic consistency of T2 the second layer of semantic consistency. To dene such a conversation, we rely on a set of services (A, B ∈ Service) and a set of document types (T1 ∈ Type). We do not explicitly dene the type of the system associated with the messages exchanged between documents, but it encompasses the type of the system for XML. Formal.Semantics.on.Services.Interactions We can dene the semantics of a conversation as the set of typed interaction his- tories that can arise when executing the conversation between two Web services. We map a conversation to a set of interaction histories as a two-step process: We map a conversation to an intermediate representation, called a typed interaction history, and we then dene a conformance relation between interaction histories and typed interaction histories. A typed interaction history is a typed trace. That is, the elements of a typed interaction history include the types of information that may be exchanged in a conversation. We map a given conversation to a set of typed interaction histories, and the value and type of the message container within the conversation. We then dene a notion of conformance between interaction histories and typed interaction histories. Denition 12 A typed interaction history is a trace with the type of information for the observable actions, where each typed action has the following format. • A typed action E is a member of the set {A-S(T2:T1(v)), A-R(T2:T1(v)), A- A(T2:T1(v), A-C(T2:T1(v))}, where • A-S(T2:T1(v)) represents the action that service A sends a value v that matches or validates against the templates of T2 and T1, • A-R(T2:T1(v)) represents the action that service A receives a value v that matches or validates against the templates of T2 and T1, • A-A(T2:T1(v)) represents the action that service A aborts a send of a value v that matches or validates against the template of T2 and T1, and • A-C(T2:T1(v)) represents the action that service A commits a send of a value v that matches or validates against the template of T2 and T1. Three-Point Service-Oriented Design and Modeling Methodology for Web Services 193 Copyright © 2007, Idea Group Inc. Copying or distributing in print or electronic forms without written permission of Idea Group Inc. is prohibited. Denition 13 The set of the valid typed interaction history T is dened as follows. 1. λ ∈ T. 2. For any typed action E and typed interaction history t ∈ T, E.t ∈ T. A typed action E is said to occur in a typed interaction history t if t = 1 t .E. 2 t . We write E ∈ t if typed action E occurs in typed interaction history t. In essence, a typed interaction history is like an interaction history except for the fact that it has templates of documents or types of the values associated with the actions as opposed to the actual values themselves. Denition 14 Given an interaction i of the form A → B: T2: T1(v), the interaction semantics of i is the set {A-S(T2:T1(v)).A-C(T2:T1(v)).B-R(T2: T1(v))}. We write i ⇒ S if S is the semantics of the interaction i. This typed interaction history captures the fact that one of the end points of the interaction did a successful send followed by a commit, while the other end of the interaction did a successful receive. Denition 15 Given two sets of typed interaction histories 1 T and 2 T , the concatenation T of 1 T and 2 T (written as T = 1 T . 2 T ) is dened as a set of sequences whose elements are made by concatenating any elements of the rst set with any element of the second set. Denition 16 Given a conversation denition of the form c = i 1 ;c ' , where i 1 is a simple interac- tion of the form A → B: T2: T1(v) and c ' is a conversation fragment, c ' can be the interaction fragment or the evaluation of a holder function, or it can be both the interaction fragment and the evaluation of a holder function. Suppose further that i 1 ⇒ S i1 and c ' ⇒ S c' . The set S c such that c ⇒ S c is dened as S c = S i1 ⋅ S c' . 194 Gao & Chung Copyright © 2007, Idea Group Inc. Copying or distributing in print or electronic forms without written permis- sion of Idea Group Inc. is prohibited. The.Formal.Semantics.of.the.Standard.Schemes In terms of the standard schemes for the ordering service of an order-handing system (one supplier) and Denitions 13 and 15, we would like to address the formal seman- tics of the standard schemes on the conceptual system level by taking the example of the ordering service of an order-handing system. In this chapter, the denitions of schemes have general meanings and are not limited to a concrete example. The.Formal.Semantics.of.Scheme.A For Scheme A, the conversation fragment including records of matching message holders and received messages is: Holder(Order-mess-holder) = C: Order(a); Buyer → Agent: C: Order(a); Holder(Orderline-mess-holder) = C: Order(a); Agent → Supplier: C: Order(a). Evaluating Holder(Product-Mess-Holder) Holder(Product-mess-holder) = C: Order(a); Supplier → Agent: C: Order(a); Holder(Orderline-mess-holder) = C: Order(a); Agent → Buyer: C: Order(a); Holder(Order-mess-holder) = C: Order(a). Correspondingly, the semantics of the conversation with the interaction semantics are the following. Holder(Order-mess-holder) = C: Order(a). {Buyer-S(C: Order(a)).Buyer-C(C: Order(a)).Agent-R(C: Order(a))}. Holder(Orderline-mess-holder) = C: Order(a). {Agent-S(C: Order(a)).Agent-C(C: Order(a)).Supplier-R(C: Order(a))}. Evaluating Holder(Product-Mess-Holder) Holder(Product-mess-holder) = C: Order(a). {Supplier-S(C: Order(a)).Supplier-C(C: Order(a)).Agent-R(C: Order(a))}. Three-Point Service-Oriented Design and Modeling Methodology for Web Services 195 Copyright © 2007, Idea Group Inc. Copying or distributing in print or electronic forms without written permission of Idea Group Inc. is prohibited. Holder(Orderline-mess-holder) = C: Order(a). {Agent-S(C: Order(a)).Agent-C(C: Order(a)).Buyer-R(C: Order(a))}. Holder(Order-mess-holder) = C: Order(a). The semantics of Scheme B and Scheme C can be represented as those of Scheme A. Denition 17 We can dene Scheme A, Scheme B, and Scheme C as positive (denoted with *) schemes since they are all successful. Correspondingly, their formal semantics can be expressed in the following: st (Scheme A) = (* C S ) st (Scheme B) = (* M S ) st (Scheme C) = (* F S ). The Formal Semantics of Scheme D For Scheme D, the conversation fragment including records of matching message holders and received messages is: Holder(Order-mess-holder) = C: Order(a); Buyer → Agent: C: Order(a); Holder(Orderline-mess-holder) = C: Order(a); Agent → Supplier: C: Order(a). Evaluating Holder(Product-Mess-Holder) Holder(Product-mess-holder) ≠ C: Order(a); Due to Denition 5, Holder(Orderline-mess-holder) ≠ C: Order(a); Holder(Order-mess-holder) ≠ C: Order(a). In the above conversation fragment, the three-point cooperative principle, which is deducted from the lemmas of the message-dependency rules, can act as the reasoning engine within the conversation between the services; that is, if one parent role wants 196 Gao & Chung Copyright © 2007, Idea Group Inc. Copying or distributing in print or electronic forms without written permis- sion of Idea Group Inc. is prohibited. to take one of three activities (C, M, F), its activity needs to obtain the agreement of the other parent role and be conrmed by the intermediary role. Correspondingly, the semantics of the conversation with the interaction semantics are the following. Holder(Order-mess-holder) = C: Order(a). {Buyer-S(C: Order(a)).Buyer-C(C: Order(a)).Agent-R(C: Order(a))}. Holder(Orderline-mess-holder) = C: Order(a). {Agent-S(C: Order(a)).Agent-C(C: Order(a)).Supplier-R(C: Order(a))}. Evaluating Holder(Product-Mess-Holder) Holder(Product-mess-holder) ≠ C: Order(a). Due to Denition 5, Holder(Orderline-mess-holder) ≠ C: Order(a); Holder(Order-mess-holder) ≠ C: Order(a). The semantics of Scheme E and Scheme F can be represented as those of Scheme D. Denition 18: We can dene Scheme D, Scheme E, and Scheme F as negative (denoted with !) schemes since they are not successful. Correspondingly, their formal semantics can be expressed in the following: st (Scheme D) = (! C S ) st (Scheme E) = (! M S ) st (Scheme F) = (! F S ). The Schemes of Canceling an Order in the Order-Handling System of One Sup- plier. In the following, we would like to address the situation of canceling. Three-Point Service-Oriented Design and Modeling Methodology for Web Services 197 Copyright © 2007, Idea Group Inc. Copying or distributing in print or electronic forms without written permission of Idea Group Inc. is prohibited. Scheme.G: One buyer would like to book goods and sends the order message. This piece of information is passed to the supplier by the agent. At the same time the agent is preparing to send this message to supplier (denoted as ||), the buyer wants to cancel the order and sends the canceling information to the agent. We assume the buyer has priority over the supplier, denoted as Buyer ∠ Supplier. The.Formal.Semantics.of.Scheme.G The conversation fragment including records of matching message holders and received messages is (Buyer ∠ Supplier) Holder(Order-mess-holder) = C: Order(a); Buyer → Agent: C: Order(a); Holder(Orderline-mess-holder) = C: Order (a); Agent → Supplier: C: Order(a) || Buyer → Agent: QC: Order(a). When evaluating Holder(Product-mess-holder), Holder(Product-mess-holder) ≠ C: Order(a). Due to Denition 5, Holder(Orderline-mess-holder) ≠ C: Order(a); Holder(Order-mess-holder) ≠ C: Order(a). Correspondingly, the semantics of the conversation with the interaction semantics are the following. Holder(Order-mess-holder) = C: Order(a). {Buyer-S(C: Order(a)).Buyer-C(C: Order(a)).Agent-R(C: Order(a))}. Holder(Orderline-mess-holder) = C: Order(a). {Agent-S(C: Order(a)).[Buyer-S(QC: Order(a)).Buyer-C(QC:Order(a)). Agent-R(QC:Order(a))].Agent-A(C:Order(a))}. Evaluating Holder(Product-Mess-Holder) Holder(Product-mess-holder) ≠ C: Order(a). Due to Denition 5, Holder(Orderline-mess-holder) ≠ C: Order(a); Holder(Order-mess-holder) ≠ C: Order(a). 198 Gao & Chung Copyright © 2007, Idea Group Inc. Copying or distributing in print or electronic forms without written permis- sion of Idea Group Inc. is prohibited. Scheme.H: The buyer would like to change the content of the booking and sends the modied message. This piece of information is passed to the supplier by the agent. At the same time the agent is preparing to send this message to supplier, the buyer wants to cancel this change and sends the canceling information to the agent. We assume the buyer has priority over the supplier. Scheme.I: The Supplier fullls the contract. This piece of information is passed to the buyer by the agent. At the same time, the buyer cancels the order (we assume the buyer has priority over the supplier). Therefore, the order is not fullled by the supplier. (Within one transaction, this canceling may occur in one of the three phases C, M, or F.) The semantics of Scheme H and Scheme I can be represented as those of Scheme G. Denition 19 We can dene Scheme G, Scheme H, and Scheme I as negative schemes with can- celing (denoted with #). Correspondingly, their formal semantics can be expressed in the following: st (Scheme G) = (# C S ) st (Scheme H) = (# M S ) st (Scheme I) = (# F S ) . Phase Scheme Positive or Negative Semantics Expression Creating A Positive (* C S ) Creating D Negative (! C S ) Creating G Negative with Canceling (# C S ) Modifying B Positive (* M S ) Modifying E Negative (! M S ) Modifying H Negative with Canceling (# M S ) Fullling C Positive (* F S ) Fullling F Negative (! F S ) Fullling I Negative with Canceling (# F S ) Table 1. Formal semantics of the ordering of an order-handling system of one sup- plier Three-Point Service-Oriented Design and Modeling Methodology for Web Services 199 Copyright © 2007, Idea Group Inc. Copying or distributing in print or electronic forms without written permission of Idea Group Inc. is prohibited. Denition 20 Because the semantics of the canceling means there is no possibility of success, the parts of Scheme G, Scheme H, and Scheme I are the same as those of Scheme D, Scheme E, and Scheme F. Correspondingly, the semantics of Scheme D from evaluating Holder(Product- mess-holder) are the same as those of Scheme G. The semantics of Scheme E from evaluating Holder(Product-mess-holder) are the same as those of Scheme H, and the semantics of Scheme F from evaluating Holder(Order-mess-holder) are the same as those of Scheme I. In summary, the formal semantics of the ordering of an order-handling system of one supplier can be summarized in the following table. Denition 21 For any set of semantics of conversation S and nite integer i, S i = S.S.S… i times. Denition 22 In terms of the positive schemes, the successful standard semantics specication (denoted as SP) of the system within one life cycle of one transaction can be ex- pressed as follows: • SP = (* S c ) 1 ⋅(*S M )i⋅(*S F ) 1 , where i is a nite integer. Formal. History. Conformance Local.History.Conformance.to.Schemes In Denition 6 and Denition 7, we formally dened the valid interaction history. In Denition 12 and Denition 13, we formally dened the valid typed interaction history. We also formally dened local typed traces, which we call the formal se- mantics of schemes (in terms of the ordering service of an order-handling system of 200 Gao & Chung Copyright © 2007, Idea Group Inc. Copying or distributing in print or electronic forms without written permis- sion of Idea Group Inc. is prohibited. one supplier). In the following, we rst dene the local history, and then we dene the local history conformance to the formal semantics of schemes. Denition 23: Local History In terms of our three-point service-oriented design and modeling methodology for Web-services composition, on the conceptual system level, given two services A and B and their message holders, we dene the local history (denoted as lh) to be a set of history scripts, which includes all the values of the message holder function, the valid interaction history, the evaluating message holder, and the reasoning scripts from Service A to Service B. Denition 24 For any set of local history lh and the nite integer i, (lh) = i (lh).(lh).(lh)… i times. Denition 25: The Conformance Relation Between the Local History and the Formal Semantics of Schemes (Scheme A…Scheme I) In the following, we dene a conformance relation between the local history and the formal semantics of the schemes (Scheme A…Scheme I). Given a local history and a scheme, if lh ≈ st(Scheme A…Scheme I), we say lh conforms to st (Scheme A Scheme I). Next we would like to dene them in detail in terms of the individual schemes. The conformance relation has two aspects. There is a structure aspect, requiring that the sequences agree between a local history and the formal semantics of a scheme, which includes the sequence of interactions, the matching or validating of the holder value, the evaluation of the holder, and the reasoning results. There is also a value aspect, which requires that the data exchanged as part of the history match or validate against the templates in the formal semantics of the schemes. Denition 26: Well-Formed Local History A local history is said to be well formed if it conforms to the formal semantics of one of the schemes (Scheme A…Scheme I). Three-Point Service-Oriented Design and Modeling Methodology for Web Services 201 Copyright © 2007, Idea Group Inc. Copying or distributing in print or electronic forms without written permission of Idea Group Inc. is prohibited. Successful History of One Life Cycle of One Transaction Denition 27: Successful History of One Life Cycle of One Transaction In Denition 22, we dened the successful standard semantics specication of a system within one life cycle of one transaction. Here we dene the successful history of one life cycle of one transaction. A history (denoted as His) of one life cycle of one transaction is said to be successful if one of the following conditions holds. A: If there is no modication within one life cycle of one transaction, then [ 1 lh ≈ (* C S )] 1 .[ 2 lh ≈ (* F S )] 1 . (4) B: If there are i (i ≥ 1) modications within one life cycle of one transaction, then [ 1 lh ≈ (* C S )] 1 . [ )1 (2 i lh + ≈ (* M S )] i . [ ) 2 ( i lh + ≈ (* F S )] 1 , (5) where i (i ≥ 1) is a nite integer. According to Denition 17, Denition 18, and Denition 19, a successful history of one life cycle of one transaction can be expressed in one of the following expres- sions as well. A: If there is no modication within one life cycle of one transaction, then [ 1 lh ≈ st (Scheme A)] 1 .[ 2 lh ≈ st (Scheme C)] 1 . (6) B: If there are i (i ≥ 1) modications within one life cycle of one transaction, then [ 1 lh ≈ st (Scheme A)] 1 . [ )1 (2 i lh + ≈ st (Scheme B)] i . [ ) 2 ( i lh + ≈ st (Scheme C)] 1 , (7) where i (i ≥ 1) is a nite integer. [...]... rights to the partition) Mobile computing has changed the face of computing in recent times, as well as introduced new and challenging problems in data management In today’s scenario, many employees work away from the office, interacting with clients and collecting data Sometimes mobile devices do not have enough space to store the data, while at other times employees need to access real-time data from. .. participants If all votes including the coordinator’s vote are yes, then the coordinator decides to commit and sends the message accordingly to all the sites Even if just one of the votes is no, the coordinator decides to abort the distributed transaction After receiving the commit or abort decision from the coordinator, the participant commits or aborts accordingly from the prepared state There are two phases... Retrieved from http://www-4.ibm.com/software/solutions/webservices/pdf/ WSFL.pdf Milner, R (1980) A calculus of communicating systems (LNCS 92) Springer Verlag Service framework specification (2001) Retrieved from http://www.hpl.hp.com/ techreports/2001/HPL-2001-138.HTML Shirky, C (2002) Web services and context horizons Computer, 93-94 Snell, J (2004) The Web services insider: Part 5 Getting into the... the Web service architecture Retrieved from http://www.citeseer.com Thatte, S (2001) XLANG: Web services for business process design Microsoft Corporation Retrieved from http://www.gotdotnet.com/team/xml_wsspecs/ xlang-c/default.htm Universal description, discovery and integration (UDDI) (2003) Retrieved from http://www.uddi.org/ Web services conversation language (WSCL) 1.0 (2002) Retrieved from http://www... (15) where i (i ≥ 1) is a finite integer In terms of our three-point service- oriented design and modeling methodology for Web-services composition, given the fact that there is a service buyer and service supplier, the intermediary service is the service agent When equation 8 happens within one life cycle of one transaction, the service buyer does not successfully create an order Copyright © 2007,... creation: If strict data consistency is to be maintained, performance is severely affected if a new replica is to be created Sites will not be able to fulfill requests due to consistency requirements 3 Maintenance overhead: If the files are replicated at more then one site, they occupy storage space and have to be administered Thus, there are overheads in storing multiple files 4 Lower write performance:... is required to read and write replicated data items The most simple replica-control protocol is the read-one-write-all (ROWA) protocol In the ROWA protocol, a transaction requests to read an item and the system fetches the value from the most convenient location If a write operation is requested, the system must update all the replicas It is clearly evident that the read operation benefits from data... The coordinator sends a vote_request to all the participating sites After receiving the request to vote, the site responds by sending its vote, either yes or no If the participant voted yes, it enters a prepared or ready state and waits for the final decision from the coordinator If the vote was no, the participant can abort its part of the transaction The coordinator collects all votes from the participants... without written permission of Idea Group Inc is prohibited Three-Point Service- Oriented Design and Modeling Methodology for Web Services 205 Essentially, these two theorems tell us that it is possible to decide whether a local history conforms to the formal semantics of one of the schemes In addition, if a local history does not conform to the formal semantics of one of the schemes, we can determine the... phase under the condition that the service buyer has priority over the service supplier When equation 14 happens within one life cycle of one transaction, the service buyer and service supplier successfully complete one life cycle of one transaction without modifying the order When equation 15 happens within one life cycle of one transaction, the service buyer and service supplier successfully complete . methodology for Web-services composition, on the conceptual system level, given two services A and B and their message holders, we dene the local history (denoted as lh) to be a set of history scripts,. function, the valid interaction history, the evaluating message holder, and the reasoning scripts from Service A to Service B. Denition 24 For any set of local history lh and the nite integer. three-point service- oriented design and modeling methodology for Web-services composition, given the fact that there is a service buyer and service supplier, the intermediary service is the service