1 Introduction
1.1 Web service composition and verification
# | Service name | Input(s) | Output(s) | respTime |
---|---|---|---|---|
1 | HotelReserveService (HR) | Dates, Hotel | HotelReservation | 5 |
2 | CityHotelService (CH) | City | Hotel | 3 |
3 | HotelCityService (HC) | Hotel | City | 3 |
4 | HotelPriceInfoService (HP) | Hotel | Price | 10 |
5 | SightseeingCityService (SC) | Sightseeing | City | 2 |
6 | SightseeingCityHotelService (SCH) | Sightseeing | City, Hotel | 16 |
7 | CitySightseeingService (CS) | City | Sightseeing | 4 |
8 | ActivityBeachService (ABS) | Activity | Beach | 5 |
9 | AreaWeatherService (AWS) | Area | Weather | 5 |
10 | CityWeatherService (CWS) | City | Weather | 5 |
Constraint | Value | |
---|---|---|
Hard constraint: | Input: |
Dates, Sightseeing
|
Output: |
Price, HotelReservation
| |
Soft constraint: |
\(respTime \le 30 \)
| |
Temporal relation: |
\(\square (\lnot HotelReservation\) U Price) |
1.2 Web service indexing
-
We propose an approach to represent the Web services by the Labelled Transition System (LTS), known as LTS4WS, to serve for the application of model checking for Web service composition.
-
We use the LTS4WS model to verify the hard and soft constraints on WSC. This model checking approach allows us to verify temporal relation on the constraints as well.
-
We apply some heuristic based on the characteristics of Web service when performing model checking, so verification performance is improved visibly.
-
We proposed an approach which combines indexing and model checking for composition and verification of Web services. Compared with [10], this work is enhanced with indexing technique to enjoy a significant improvement of performance.
-
We presented a bitwise-based approach to present Web services and indexing technique. This representation allows us to use the bitwise operators in processing and further enjoy more improvement on performance.
-
The experiments are performed on multiple real data sets and the results show the effectiveness of this approach compared with [10] and other approaches.
2 LTS4WS—the model for Web service composition
-
\(\mathcal {N}\) is a string representing the unique name of \(\mathcal {W}\).
-
\(\mathcal {I}=\{t^i_1, t^i_2, \ldots , t^i_n\}\) is a set of input functional properties. We denote \(\widetilde{t^i_j}\) as an input logical term representing the current informative status of the property \(t^i_j\). \(\widetilde{t^i_j}=true\) means that the information of \(t^i_j\) is currently available and vice versa.
-
\(\mathcal {O}=\{t^o_1, t^o_2, \ldots , t^o_m\}\) is a set of output functional properties. We denote \(\widetilde{t^o_k}\) as an output logical term representing the current informative status of the property \(t^o_k\). Likewise, \(\widetilde{t^o_k}=true\) means that the information of \(t^o_k\) is currently available and vice versa.
-
\(\mathcal {P}\) is a logic expression representing the pre-condition of \(\mathcal {W}\) that must hold before \(\mathcal {W}\) is invoked. It is simply a conjunctive normal form of all input logical terms, as \(\mathcal {P}=\widetilde{t^i_1} \wedge \widetilde{t^i_2} \wedge \ldots \wedge \widetilde{t^i_n} = \bigwedge ^{n}_{j} \widetilde{t^i_j}\).
-
\(\mathcal {E}\) is a set of assignment expressions describing the effect after \(\mathcal {W}\) is invoked. \(\mathcal {E}\) has the form of \(\{\forall k=1..m:\widetilde{t^o_k} \overset{\scriptscriptstyle \Delta }{=} true\}\), where \(\overset{\scriptscriptstyle \Delta }{=}\) is the assignment operator. Because \(\widetilde{t^o_k}\) is a logical term, we can simply represent it as \(\{\forall k = 1 \ldots m: \widetilde{t^o_k}\}\) or \(\{\widetilde{t^o_1}; \ldots ; \widetilde{t^o_m};\}\).
-
\(\mathcal {Q}\) is a set of QoS properties, each of which is a pair of \(\langle name: value \rangle \), where name is the name of the property and value is a numerical amount which evaluates the value returned by \(\mathcal {W}\) w.r.t this property.
-
V is a set of variables,
-
S is a set of states,
-
\(s_0 \in S\) is the initial state,
-
L is a set of action labels,
-
\(\delta : S \times L \rightarrow S\) is a transition relation, where \((s, a, s')\in \delta \) is denoted as \((s \times a \rightarrow s')\). A transition may also have a pre-condition (or the guard), a logical expression built over V, which must always hold before the transition is fired. In addition, a transition may also have an effect, a set of expressions built over V, which expresses the effect after firing the transition. A LTS that supports those kinds of transitions is called guarded LTS, whose transition is represented as:$$\begin{aligned}{}[guard ] transition [effect ] \end{aligned}$$
-
\(V = \{\widetilde{Hotel}, \widetilde{Dates}, \widetilde{HotelReservation}\}\),
-
\(S = \{start,end\},\)
-
\(s_0 = start,\)
-
\(L =\{HR\},\)
-
\(\delta = \{[\widetilde{Hotel}\wedge \widetilde{Dates}] start \times HR \rightarrow end\) \([\widetilde{HotelReservation}]\}\)
-
\(V = (\bigcup _{i}^{n}\mathcal {I}_i)\bigcup (\bigcup _{i}^{n}\mathcal {O}_i).\)
-
\(\{s_0\}\) is a set of states, which has only one state \(s_0\),
-
\(s_0\) is the initial state,
-
\(L= \{\mathcal {N}_1, \mathcal {N}_2, \ldots , \mathcal {N}_n\}\),
-
\(\delta \) is a transition relation of the form \([\mathcal {P}_i] s_0 \times \mathcal {N}_i\rightarrow s_0 [{\mathcal {E}_i}]\).
-
The set of variables: V = \(\{\widetilde{Dates}\), \(\widetilde{Hotel}\), \(\widetilde{HotelReservation}\), \(\widetilde{City}\), \(\widetilde{Price}\), \(\widetilde{Sightseeing}\), \(\widetilde{Activity}\), \(\widetilde{Beach}\), \(\widetilde{Area}\), \(\widetilde{Weather}\)}
-
The set of states: {\(s_0\)}
-
The initial state: \(s_0\)
-
The set of label actions is the acronym of the name of web services: L={HR, CH, HC, HP, SC, SCH, CS, ABS, AWS, CWS}
-
The transition relations: \(\delta \) = { \([\widetilde{Hotel}\wedge \widetilde{Dates}]\) \(s_0 \times HR \rightarrow s_0\) \([\widetilde{HotelReservation}]\), \([\widetilde{City}]\) \(s_0 \times CH \rightarrow s_0\) \([\widetilde{Hotel}]\), \([\widetilde{Hotel}]\) \(s_0 \times HC \rightarrow s_0\) \([\widetilde{City}]\), \([\widetilde{Hotel}]\) \(s_0 \times HP \rightarrow s_0\) \([\widetilde{Price}]\), \([\widetilde{Sightseeing}]\) \(s_0 \times SC \rightarrow s_0\) \([\widetilde{City}]\), \([\widetilde{Sightseeing}]\) \(s_0 \times SCH \rightarrow s_0\) \([\widetilde{City}; \widetilde{Hotel}]\), \([\widetilde{City}]\) \(s_0 \times CS \rightarrow s_0\) \([\widetilde{Sightseeing}]\), \([\widetilde{Activity}]\) \(s_0 \times ABS \rightarrow s_0\) \([\widetilde{Beach}]\), \([\widetilde{Area} \wedge \widetilde{Dates}]\) \(s_0 \times AWS \rightarrow s_0\) \([\widetilde{Weather}]\), \([\widetilde{City} \wedge \widetilde{Dates}]\) \(s_0 \times CWS \rightarrow s_0\) \([\widetilde{Weather}]\)}
3 Heuristics-based approaches for web service composition
-
G(n) is the real cost from state init to state n,
-
\(\alpha , \beta \) are the corresponding weights of H(n) and G(n).
-
H(n) is the estimated cost (heuristic) from n to goal, as$$\begin{aligned} H(n) = \beta _1 H1(n) + \beta _2 H2(n), \end{aligned}$$(2)
-
H1(n) is the estimated cost based on the QoS properties,
-
H2(n) is the estimated cost based on the functional properties,
-
\(\beta _1, \beta _2\) are the corresponding weights of H1(n) and H2(n).
-
i is the number of composition step from init to n.
-
l is the number of functional properties that composite Web service must be satisfied.
-
If Q is a negative property, then$$\begin{aligned} q_{\text {{nrm}}} = {\left\{ \begin{array}{ll} \frac{q-q_{\text {{min}}}}{q_{\text {{max}}}-q_{\text {{min}}}} &{}\quad \text {if }\, q_{\text {{max}}}-q_{\text {{min}}} \ne 0 \\ 1 &{}\quad \text {if }\, q_{\text {{max}}}-q_{\text {{min}}} = 0. \end{array}\right. } \end{aligned}$$(4)
-
If Q is a positive property, then$$\begin{aligned} q_{\text {{nrm}}} = {\left\{ \begin{array}{ll} \frac{q_{\text {{max}}}-q}{q_{\text {{max}}}-q_{\text {{min}}}} &{}\quad \text {if }\, q_{\text {{max}}}-q_{\text {{min}}} \ne 0 \\ 1 &{}\quad \text {if }, q_{\text {{max}}}-q_{\text {{min}}} = 0. \end{array}\right. } \end{aligned}$$(5)
-
\(w_i\) is the weight of property ith, which can be changed by user. By default, all QoS properties have \(w_i=1\).
-
\(q_{\text {{nrm}}_i}\) is a normalized value of property ith at state n.
-
The initial state (init): \(H1=0\)
-
The state after invoking the SC service (SightseeingCityService) (state SC in Fig. 5): – The response time: \(q_{{\text {nrm}}_1} = \frac{2-1}{60-1} = 0.0169\) – \(H1 = \sum w_i*q_{{\text {nrm}}_i} = 0.0169\)
-
\({{\mathrm{funcvar}}}(x)\) is a set of functional properties which we will have (whose value is 1) at the state x.
-
\({{\mathrm{diff}}}(A, B)\) is a function which counts the number of functional properties appear in A, but does not appear in B. Thus, \({{\mathrm{diff}}}({{\mathrm{funcvar}}}(goal), {{\mathrm{funcvar}}}(n))\) is the number of functional properties required by users that have not yet achieved at state n. When \({{\mathrm{diff}}}({{\mathrm{funcvar}}}(goal), {{\mathrm{funcvar}}}(n))=0\), in aspect of functionality, state n satisfies the user requirements.
-
The initial state (init):– \({{\mathrm{funcvar}}}{(init)}=\{Sightseeing, Dates\}\) – \(H2(init) = \frac{{{\mathrm{diff}}}({{\mathrm{funcvar}}}(goal),{{\mathrm{funcvar}}}(init))}{l} = \frac{2}{2} = 1\)
-
The state after invoking the HP service (HotelPriceInfoService) (state HP in Fig. 5): – \({{\mathrm{funcvar}}}{(HP)}=\{Sightseeing, Dates, City, Hotel, Price\}\) – \(H2(HP) =\frac{{{\mathrm{diff}}}({{\mathrm{funcvar}}}(goal),{{\mathrm{funcvar}}}(HP))}{l} = \frac{1}{2} = 0.5\).
4 Bitwise-based Web service indexing
4.1 Index table construction and manipulation
4.1.1 The ordered feature set of Web service repository
4.1.2 Bitwise-based vectors of a Web service and user functional requirements
# | Web service | Bitwise-based input vector | Bitwise-based output vector |
---|---|---|---|
1 | HotelReserveService (HR) | 000001100000 | 000000010000 |
2 | CityHotelService (CH) | 000010000000 | 000000100000 |
3 | HotelCityService (HC) | 000000100000 | 000010000000 |
4 | HotelPriceInfoService (HP) | 000000100000 | 000000001000 |
5 | SightseeingCityService (SC) | 000000000010 | 000010000000 |
6 | SightseeingCityHotelService (SCH) | 000000000010 | 000010100000 |
7 | CitySightseeingService (CS) | 000010000000 | 000000000010 |
8 | AdventureRuralAreaService (ARA) | 010000000000 | 000000000100 |
9 | ActivityBeachService (ABS) | 100000000000 | 000100000000 |
10 | AreaWeatherService (AWS) | 001000000000 | 000000000001 |
User requirement | Bitwise-based supplied vector | Bitwise-based goal vector |
---|---|---|
Input: Dates, Sightseeing
| 000001000010 | 000000011000 |
Output: Price, HotelReservation
|
4.1.3 Bitwise-based indexing for Web service repository
Index item | List of Web services |
---|---|
100000000000 |
\(\langle \)100000000000,000100000000\(\rangle \) (ABS) |
010000000000 |
\(\langle \)010000000000,000000000100\(\rangle \) (ARA) |
001000000000 |
\(\langle \)001000000000,000000000001\(\rangle \) (AWS) |
000100000000 | |
000010000000 |
\(\langle \)000010000000,000000100000\(\rangle \) (CH), |
\(\langle \)000010000000,000000000010\(\rangle \) (CS) | |
000001000000 |
\(\langle \)000001100000,000000010000\(\rangle \) (HR) |
000000100000 |
\(\langle \)000001100000,000000010000\(\rangle \) (HR), |
\(\langle \)000000100000,000010000000\(\rangle \) (HC), | |
\(\langle \)000000100000,000000001000\(\rangle \) (HP) | |
000000010000 | |
000000001000 | |
000000000100 | |
000000000010 |
\(\langle \)000000000010,000010000000\(\rangle \) (SC), |
\(\langle \)000000000010,000010100000\(\rangle \) (SCH) | |
000000000001 |
4.1.4 Choosing indexing items and choosing Web services
4.1.5 Reducing the number of chosen Web services
4.1.6 The satisfied composite Web service
4.2 Case study
Current input features | Current input vector (V) | Chosen index | Chosen web services | ||
---|---|---|---|---|---|
WS | Bitwise-based input vector | Bitwise-based output vector | |||
Sightseeing, Dates | 000001000010 | 000001000000 | HR | 000001100000 | 000000010000 |
000000000010 | SC | 000000000010 | 000010000000 | ||
SCH | 000000000010 | 000010100000 |
Current input features | Current input vector (V) | Chosen index | Chosen web services | ||
---|---|---|---|---|---|
WS | Bitwise-based input vector | Bitwise-based output vector | |||
Sightseeing, Dates, City | 000011000010 | 000001000000 | HR | 000001100000 | 000000010000 |
000000000010 | SCH | 000000000010 | 000010100000 | ||
000010000000 | CH | 000010000000 | 000000100000 |
Current input features | Current input vector (V) | Chosen index | Chosen web services | ||
---|---|---|---|---|---|
WS | Bitwise-based input vector | Bitwise-based output vector | |||
Sightseeing, Dates, City, Hotel | 000011100010 | 000001000000 | HR | 000001100000 | 000000010000 |
000000000010 | |||||
000010000000 | |||||
000000100000 | |||||
HP | 000000100000 | 000000001000 |
Current input features | Current input vector (V) | Chosen index | Chosen web services | ||
---|---|---|---|---|---|
WS | Bitwise-based input vector | Bitwise-based output vector | |||
Sightseeing, Dates, City | 000011100010 | 000001000000 | HR | 000001100000 | 000000010000 |
000000000010 | |||||
000010000000 | |||||
000000100000 | |||||
000000001000 |
There is no web service
|
5 Experimentations
Data set | No. of Web services | Description |
---|---|---|
Travel Booking (TB) | 20 | Including web services providing information to serve the travel booking |
Medical Services (MS) | 50 | Services support to look up hospital, treatment, medicine, etc. |
Education Services (EDS) | 100 | Services related to education, such as scholarship, courses, degrees, etc. |
Economy Services (ECS) | 200 | Including services provided information on goods, restaurant, food, etc. |
Global | 1000 | 1000 random services from OWL-S-TC [17] |
Data sets | Approaches | Expanded states | Visited states | Execution time (s) |
---|---|---|---|---|
TB (20) | Full schema verification | 1100 | 56 | 0.250 |
On-the-fly composition and verification | 825 | 56 | 0.210 | |
Heuristic-driven on-the-fly composition and verification | 316 | 35 | 0.155 | |
Combined bitwise-based indexing with heuristic-driven on-the-fly composition and verification | 316 | 35 | 0.155 | |
MS (50) | Full schema verification | 16,720 | 210 | 2.597 |
On-the-fly composition and verification | 12,331 | 210 | 2.022 | |
Heuristic-driven on-the-fly composition and verification | 2143 | 119 | 1.538 | |
Combined bitwise-based indexing with heuristic-driven on-the-fly composition and verification | 316 | 35 | 0.155 | |
EDS (100) | Full schema verification | 27,400 | 275 | 5.570 |
On-the-fly composition and verification | 20,824 | 275 | 4.579 | |
Heuristic-driven on-the-fly composition and verification | 3021 | 151 | 3.294 | |
Combined bitwise-based indexing with heuristic-driven on-the-fly composition and verification | 316 | 35 | 0.155 | |
ECS (200) | Full schema verification | 102,800 | 515 | 28.198 |
On-the-fly composition and verification | 76,586 | 515 | 23.030 | |
Heuristic-driven on-the-fly composition and verification | 8324 | 287 | 18.273 | |
Combined bitwise-based indexing with heuristic-driven on-the-fly composition and verification | 316 | 35 | 0.155 | |
Global (1000) | Full schema verification | Out-of-memory | Out-of-memory | Out-of-memory |
On-the-fly composition and verification | Out-of-memory | Out-of-memory | Out-of-memory | |
Heuristic-driven on-the-fly composition and verification | 91,457 | 1429 | 597.228 | |
Combined bitwise-based indexing with heuristic-driven on-the-fly composition and verification | 316 | 35 | 0.155 |
6 Related works
6.1 Web service composition and verification
6.1.1 Composition based on hard constraints
6.1.2 Composition based on hard and soft constraints
6.1.3 Web service verification
6.2 Web service indexing
6.3 Evaluation and comparison of our approach with other studies
Tool | Composition | Verification | Hard const. | Soft const. | Temporal | Input |
---|---|---|---|---|---|---|
OWL-S-XPlan | X | X | OWL-S | |||
PORSCE II | X | X | OWL-S | |||
WS-Engineer | X | X | BPEL | |||
AgFlow | X | X | Statechart | |||
VeriWS | X | X | X | X | BPEL | |
WSCOVER | X | X | X | X | X | OWL-S |
-
In [5], the LTS model is rebuilt when we consider new composition goal, even though the repository remains the same. In contrast, our LTS4WS model can be applied for several various goals without being rebuilt.
-
The work in [5] only verifies the composite Web service, it does not perform the composition phase. Meanwhile, our approach combines composition and verification at the same time.
-
We apply the heuristic search to model checking engine based on the characteristics of Web service, so the verification performance is improved significantly.
-
We also apply the bitwise-based indexing technique to index the Web service repository. This approach helps us to retrieve the Web services further faster and more reasonably. To the best of our knowledge, it is the first work that combines formal verification with indexing techniques in the area of Web services processing.