
idle search
GetMerchantAcc
chargeAcc
findingAccaccNotFou
nd
accFound
chargedFro
mCust
validCharge
GetCustomerAccBalance
AccNotFind
AccFind
DepositToMerchant
SucceedAtCharge
wait
Charge
Charge
FailedAtMerchantAcc
SucceedAtMerchantAcc
FailedAtCharge
WithdrawFromCustom er
FailedAtCharge
(a) Statechart Diagram for Bank
idle
getProduct
waitProduct
GetProductInfo[ true && true
&& TCvar1 <= 2 ]
browseFail
ed
browseSuc
ceed
ProductNotFind[ true && true &&
true ] / true && TCvar2=0
AddressError[ true &&
true && TCvar2<=2 ]
ProductInfo[ true && true
&& true ] / true &&
TCvar3=0
Page[ true && true
&& TCvar3<=2 ]
startNegoti
ation
waitOthers
quantity
minPrice
riskFactor
AddStatistic[ true && true && true
] / sl’ = insert(s, sl)&& TCvar4 = 0
TotalQuantity[ true && true
&& TCvar4>=3 & TCvar4<=6
] / tq’ = totalQuantity(sl)
GetMinPrice / minprice =
getMinPrice(mid, pid, tq, rul)
GetRiskBalance / rf’ =
getRiskBalance(q/tq, ril)
acceptable
Price
CalculateAcceptablePrice / ap’ =
minprice * rf
negoResult
DeleteStatistic / sl’ = delete(s, sl)
BrowseAdd[ true &&
true && true ] / true &&
TCvar1=0
Item[ true && true && true ] / s’ =
create(uid, mid, pid, q, n) & uid1’ =
uid & mid1’=mid & pid1’ = pid & q1’ =
q & n1’ = n && TCvar5=0 & TCvar6 = 0
startInvoice
Purchase
askMercha
nt
succeed
failure
GenerateInvoice
InvoiceFailed[ true && true
&& TCvar8 <= 2 ]
Unsuccessful[ true &&
true && true ] / true
&& TCvar8=0
Successful[ true && true &&
true ] / true && TCvar7 = 0
commissio
n
AddCommission / cl’ =
insert(create(mid, invid,
amount), cl)
ReceiveInvoice[
true && true &&
TCvar7<=2 ]
Confirmed[ ap <= n1
&& true && TCvar5
>= 5 & TCvar5 <= 8
]
NotConfirmed[ ap
> n1 && true &&
TCvar6 >= 5 &
TCvar6 <= 8 ]
(b) Statechart Diagram for EBroker
Figure 3: Behavior Descriptions - 2
ceives back the reply SucceedMerchantAcc, and then
responds through the message Charge. At the end
of this sequence of message exchanges, they reach
the states startCharge and chargeAcc. The Merchant
agent waits in state startCharge until the Bank agent
completes a sequence of internal computations and
sends the message SucceedAtCharge to it. Upon re-
ceiving this message, the Bank agent goes to idle
state, the Merchant agent goes to succeed state. Af-
ter completing the internal computation to record the
invoice, the Merchant agent communicates to EBro-
ker through the message Successful and their states to
idle, and succeed. At this instance, the agents Bank
and Merchant are in their idle states, the agent EBro-
ker is in state succeed, and the agent User is in state
waitinvoice. The agent EBroker records the commis-
sion earned in this transaction within 2 time units of
receiving the message ReceiveInvoice and sends the
invoice to the User. Having sent the invoice, the
agent EBroker goes to its idle state. The agent User
executes the internal message Exit and goes into its
idle state.
Figure 4 shows an E-commerce system configured
with three users, one E-broker, two merchants and
three banks. Each instance of User type models a
user with one port of type @A to communicate with
an agent of EBroker type. The E-broker agent in the
subsystem is an instance of EBroker agent type hav-
ing three ports of type @U, one port for each user; the
two ports of type @M are for communication with
the merchants in the system. Each merchant agent
in the system is an instance of Merchant agent type
with a port of type @G for communicating with the
broker agent, and three ports of type @B to commu-
nicate with the banks in the system. The agents are
linked through connectors at their respective compat-
ible ports for communication. For instance, the port
@A1 of user U 1 is linked to the port @U1 of the E-
broker E1. That link is not shared by any other agent.
Consequently, the architecture specification ensures
trust in communications.
The following section introduces a rigorous
methodology for predicting the reliability of E-
Commerce applications using Markov models con-
structed from a formal model of the E-Commerce ap-
plication.
3 MARKOV MODELS
Markov models are one of the most powerful tools
available to engineers and scientists for analyzing
complex systems. The basic concepts are explained
below.
3.1 Markov Models: Basic Concepts
Analysis of Markov models yield results for both the
time-dependent evolution of the system and the steady
state properties of the system. The Markov property
states that given the current state of the system, the
future evolution of the system is independent of its
history.
The Markov model of an E-Commerce component
may be represented by a state diagram. The states
represent the stages in the E-Commerce component
that are observable to the users, and the transitions be-
tween states have assigned probabilities. An algebraic
representation of a Markov model is a matrix, called
transition matrix, in which the rows and columns cor-
respond to the states, and the entry p
ij
in the i-th row,
j-th column is the transition probability for being in
state j at the stage following state i. We use tran-
sition matrix representation in reliability calculation
algorithms.
RELIABILITY ASSESSMENT OF E-COMMERCE APPLICATIONS
33