Professional Documents
Culture Documents
Concurrency Control RTDS
Concurrency Control RTDS
69 (2009) 866–876
communication resources. If the mobile transaction submitted to When H-MH moves to another cell, the coordinator may always
the server cannot pass the validation, it will take a long time for reside at the MSS to which the H-MH is attached. The old coordi-
the MH to be acknowledged and restart the failed transaction. For nator transfers state information to the new coordinator. The co-
a huge number of MHs, this strategy will certainly cause intolerable ordinator informs all the participants about this change.
delays and clutter the server.
The local pre-validation process is carried out against commit- 3.2. Transaction processing at MHs
ted transactions at the server in the last broadcast cycle. Data con-
flicts are detected by comparing the read set of validating mobile
3.2.1. Read/write request processing
transaction and the write set of committed transaction, since com-
mitted transactions precede the validating transaction in the seri- The MHs process the read/write requests of mobile transactions
alization order. and adjust their validation intervals. To reflect the serialization
MHs do not have a complete and up-to-date data, for instance, relation between mobile transactions and committed transactions,
the information about the commitment of some conflicting when a read/write request is processed, VI lb (Ti ) will be adjusted.
transactions that are submitted to the server after the start of the Let xk denote the version of x whose write timestamp is the largest
last broadcast cycle is known to MHS. Then, all transactions that write timestamp less than TS (Ti ). If transaction Ti issues a read(x)
pass local pre-validation at MHs have to be submitted to the server and if data item x is located in the MH, then version xk is read
for local final validation. by Ti . VI lb (Ti ) is adjusted to WST (xk ), that is, VI (Ti ) = VI (Ti ) ∩
At the server a validating transaction may be a server transac- [WTS (xk ), ∞]. The version xk is set to ReadSet (Ti ). If the data item
tions or a mobile transaction submitted by the MHs. The validat- x is not located in the MH, a subtransaction is created which has
ing transaction is ahead of every concurrently running transaction the same identity as Ti and is sent to the server. If transaction
still in read phase in serialization order. The validation of a transac- Ti issues a write(x) and if data item x is located in the MH, and
tion is done against currently running transactions. The detection if TS (Ti ) < RTS (xk ), the transaction Ti is restarted, otherwise a
of data conflicts is carried out by comparing the write set of the new version of xi is created and the new version xi will be stored
validating transaction and read set of active transactions. into Ti ’s private workspace. VI lb (Ti ) is adjusted, that is VI (Ti ) =
For a mobile update transaction submitted by a MH, it has to VI (Ti ) ∩ [WTS (xk ), ∞] ∩ [RTS (xk ), ∞]. The new version xi is set to
perform a local final backward validation before the local forward PrewriteSet (Ti ). If VI (Ti ) shuts out, Ti aborted. If Ti is a distributed
validation. The local final backward validation is necessary because transaction, then the version xi is marked as a distributed data
there may be transactions committed since the last local pre- item. If the data item x is not located in the MH, a subtransaction
validation performed at MHs. For a mobile only-only transaction is created which has the same identity as Ti and is sent to the
at the HM, it can be committed locally and does not need to be coordinator.
submitted to the server for local final validation if it passes all the The algorithm of the read request processing for mobile read-
local backward pre-validation. only transactions (MORT) is described as the following.
After local validation it is needed a global validation to ensure
distributed serializability. processing_MROT(Ti ) {
while (!End of Ti and CurrentTime < Deadline(Ti )) {
3. DMVOCC-2PLV protocol if (Ti issues read(x)) {
if (x is not located at the MH)
3.1. Commit protocol create a subtransaction and send it to the
coordinator;
The traditional commit protocols such 2PC (two phase commit), else {
3PC (three phase commit), etc., may not perform satisfactorily select version xk ;
in mobile broadcast environments mainly because of the limited // WTS (xk ) is the largest timestamp less than TS (Ti )
resources, especially communication capacity [19,6]. Therefore, VI (Ti ) = VI (Ti ) ∩ [WTS (xk ), ∞];
the 2PC commit protocol must be revised to be suitable for mobile if (VI (Ti ) == []) restart Ti ;
distributed real-time database systems. The mobile distributed else {
real-time transaction T is issued at a MH that is called Home-MH read(xk );
(H-MH). Transaction Tco at the MSS to which H-MH is attached is ReadSet (Ti ) = ReadSet (Ti ) ∪ {xk };
identified as the coordinator. If T issues a read/write request and }
H-MH cannot process it, then it creates a subtransaction Ti which }
has the same identity as T , and sends Ti to Tco . Upon the receipt of Ti }
from H-HM, Tco creates a distributed real-time transaction control if (End of Ti and CurrentTime < Deadline(Ti )) submit Ti ;
block for Ti which contains one entry, deadline, and coordinator’s }
identity. In the case of a coordinator change, a distributed real-time }
transaction control block is used to inform the new coordinator
of the status of T and commit set members. Tco distributes Ti to The algorithm of read/write request processing for mobile
the relevant server. The server, upon receiving Ti , distributes Ti to update transactions (MUT) is described as the following.
MH or FH which processes Ti . Tco waits for transaction processing
results. During Ti processing, if Ti is aborted for any reason, then processing_MUT(Ti ) {
the participant sends an abort message to Tco before the deadline while (!End of Ti and CurrentTime < Deadline(Ti )) {
of Ti expires. At the end of subtransaction, the participant sends if (Ti issues read(x)) {
a commit message to the coordinator. If the participant cannot if (x is not located at the MH)
complete its subtransaction for any reason, then it sends an abort create a subtransaction and sent it to the
message to the coordinator. T is committed when Tco has received coordinator;
all commit messages. Tco sends a commit massage to members of else {
the commit set. If Tco has received neither a commit nor an abort select version xk ;
message within the deadline of T , T is aborted. Tco sends abort // WTS (xk ) is the largest timestamp less than TS (Ti )
message to members of the commit set. VI (Ti ) = VI (Ti ) ∩ [WTS (xk ), ∞]
870 X. Lei et al. / J. Parallel Distrib. Comput. 69 (2009) 866–876
cycle, i.e., min({WTS (xk )|xk in CT _WriteSet }). The version xk of data
if (VI (Ti ) == []) restart Ti ; item x is marked valid and is not required to be validated at the
else { server. It is because Ti precedes all committed transactions which
read(xk ); write data item x in the serialization order. It is possible that a
ReadSet (Ti ) = ReadSet (Ti ) ∪ {xk }; transaction which precedes some committed transactions in the
} serialization order is validated and committed after them.
} (2) PrewriteSet (Ti ) ∩ ReadSet (Tc ) 6= ∅. This type of conflict can
} be resolved by adjusting Ti ’s validation interval to induce the se-
if (Ti issues write(x)) { rialization order Tc → Ti . This signifies the read of Tc should not
if (x is not located at the MH) affect the write of Ti . Tc precedes Ti in the serialization order. There-
create a subtransaction and send it to the fore, the adjustment of VI (Ti ) should be VI lb > TS (Tc ). That is, set
coordinator; VI (Ti ) = VI (Ti ) ∩ [TS (Tc ), ∞]. CT_ReadSet contains the data items
else { that is in the read set of the committed transactions. This rule is
select version xk ; described as the following: For the version xi of each data item x is
// WTS (xk ) is the largest timestamp less than TS (Ti ); in PrewriteSet (Ti ), if the version xj of data item x is in CT_ReadSet,
if (TS (Ti ) < RTS (xk )) restart(Ti ); VI lb (Ti ) will be set to the largest read timestamp of the version
else { of x read by committed transactions in the last broadcast cycle,
VI (Ti ) = VI (Ti ) ∩ [WTS (xk ), ∞] ∩ [RTS (xk ), ∞]; i.e., max({RTS (xk )|xk in CT _ReadSet }). It is because all committed
if (VI (Ti ) == []) abort Ti ; transactions which read data item x precede Ti in the serialization
else { order.
create a new version xi ; For the version xk of each data item x in ReadSet (Ti ), if the
PrewriteSet (Ti ) = PrewriteSet (Ti ) ∪ {xi }; version xj of data item x is in CT_WriteSet, VI ub (Ti ) will set to
} the least write timestamp of the version of x created by com-
} mitted transactions in the last broadcast cycle, i.e., min({WTS
} (xk )|xk in CT _WriteSet }). The version xk of data item x is marked
} valid and is not required to be validated at the server. It is because
} Ti precedes all committed transactions which write data item x in
if (End of Ti and CurrentTime < Deadline(Ti )) submit Ti ; the serialization order. If Ti ’s validation interval is empty, it must
} be restarted. For each item xi is in PrewriteSet (Ti ), if the version xj
of data item x is in CT_ReadSet, VI lb (Ti ) will set to the largest read
timestamp of the version of x read by committed transactions in
3.2.2. Local pre-validation the last broadcast cycle, i.e., max({RTS (xk )|xk in CT _ReadSet }). It is
At the MHs, all mobile transactions including read-only trans- because all committed transactions which read data item x pre-
actions and update transactions have to perform a local pre- cede Ti in the serialization order. If Ti ’s validation interval is empty,
validation at the beginning of a broadcast cycle. The local pre- it must be restarted. Transactions that survive in the local pre-
validation process is carried out against committed transactions at validation must be submitted to the server for local final validation.
the server in the last broadcast cycle. Data conflicts are detected For a mobile read-only transaction at MH, it can be committed
by comparing the read set of the validating mobile transaction if it passes all the local pre-validation in course of its execution.
and write set of committed transactions, since committed transac- When a mobile read-only transaction reads all the requested data
tions precede the validating transaction in the serialization order. items, and is committed, it is serialized after all committed trans-
The servers broadcast the validation information of committed actions before the beginning of the current broadcast cycle. For a
transaction in the last broadcast cycle. The validation informa- mobile update transaction, it has to be sent to the server for local
tion of transactions consists of CommitSet, AbortSet, CT_ReadSet final validation and global validation because the mobile update
and CT_WriteSet, where CommitSet is set of transactions success- transaction is serialized after all committed transactions before its
fully validated at the Server in the last broadcast cycle, AbortSet validation phase, and before all server active transactions.
is set of transactions rejected at the server in the last broadcast The algorithm of local pre-validation is described as the follow-
cycle, CT_ReadSet is read set of the committed transactions, and ing.
CT_WriteSet is write set of the committed transactions. If a mo-
bile transaction does not pass local pre-validation, then it has to be local_pre-validation(Ti ) {
restarted. Let Ti and Tc denote mobile active transaction and com- for each xk ∈ ReadSet (Ti ) {
mitted transaction in the last broadcast cycle, respectively. There if (xj ∈ CT _WriteSet) {
are two types of data conflict that can induce the serialization order VI (Ti ) = VI (Ti ) ∩ [0, min({WTS (xj )|xj ∈
between active transaction Ti and committed transaction Tc such CT _WriteSet })];
that VI (Ti ) has to be adjusted. Then, the rules to resolve data con- if (VI (Ti ) == []) abort Ti ;
flicts are given as follows. }
(1) ReadSet (Ti ) ∩ PrewriteSet (Tc ) 6= ∅. This type of conflict mark xk as valid;
can be resolved by adjusting Ti ’s validation interval to induce the }
serialization order Ti → Tc . This signifies the read of Ti should for each xi ∈ PrewriteSet (Ti ) {
not affect the write of Tc . Ti precedes Tc in the serialization order. if (xj ∈ CT _ReadSet) {
Therefore, the adjustment of VI (Ti ) should be VI ub (Ti ) < TS (Tc ). VI (Ti ) = VI (Ti ) ∩ [max({RTS (xj )|xj ∈
That is, set VI (Ti ) = VI (Ti ) ∩ [0, TS (Tc )]. CT_WriteSet contains the CT _ReadSet }), ∞];
data items that are in the write set of the committed transactions. if (VI (Ti ) == []) abort Ti ;
This rule can be described as the following: For the version xk of }
each data item x is in ReadSet (Ti ), if the version xj of data item x is in }
CT_WriteSet, VI ub (Ti ) will be set to the least write timestamp of the SubmitSet = SubmitSet ∪ {Ti };
version of x created by committed transactions in the last broadcast }
X. Lei et al. / J. Parallel Distrib. Comput. 69 (2009) 866–876 871
3.3. Transaction processing at server mobile transaction is lower than that of conflicting server active
transaction Ts , and Ts does not miss its deadline if restarted, VI (Ts )
For a mobile update transaction submitted by a MH, it has to is adjusted. Otherwise Tv is aborted.
perform a final backward validation before the forward validation. It is needed to estimate the execution time of the server trans-
The final backward validation is necessary because there may be action. Server transactions spend time performing CPU operations,
committed transactions since the last pre-validation performed and I/O operations. The time needed to get to data items can be
at the MH. Data conflicts are detected by comparing the read set estimated [5], including the waiting time due to CPU contention
of validating mobile transactions and the write set of committed (WaitCPUTime), the CPU service time (CPUTime), the waiting time
transactions, since committed transactions precede the validating due to disk condition (WaitDiskTime), the disk service time (Disk-
transactions in the serialization order. Time). Thus, the execution time for a transaction Ts to get to Num-
berData(Ts ) data items is given as follows:
Definition 1. Suppose that transaction Ti and Tj successfully create
version xi and xj of data item x, respectively. A version order is ExecutionTime(Ts ) = NumberData(Ts ) × (α × WaitCPUTime
defined as the following
+ CPUTime + PageHitRate × BufferTime + (1 − PageHitRate)
xi xj ⇔ TS (Ti ) < TS (Tj ). × (WaitDiskTime + DiskTime))
Let Tv be the validating transaction submitted by MH. For each where, PageHitRate is the page hit rate of private virtual memory.
data item xk in ReadSet(Tv ), if xk is not marked as valid, and if If the system is dynamically changing, an adaptive factor α (0 <
there exists version xk+1 , xk xk+1 , the adjustment of VI (Tv ) α ≤ 1) is included in the expression, which reflects the changes
should be VI ub (Tv ) < WTS (xk+1 ). That is, set VI (Tv ) = VI (Tv ) ∩ of the system. The protocol continuously keeps track of the aver-
[0, WTS (xk+1 )]. It is because new version xk+1 is created after Tv age of these data in the system. These measured values are used for
reads version xk . Tv should be serialized before the transaction that calculating the execution time of transactions. Let Tv and Ts denote
created version xk+1 . the validating transaction submitted by MH and server transaction,
For each data item xv in PrewriteSet (Tv ), the adjustment of respectively. Then, the rules to resolve data conflicts are given as
VI (Tv ) should be VI lb (Tv ) > max(RTS (x)). That is, set VI (Tv ) = the following.
VI (Tv ) ∩ [max(RTS (x)), ∞]. It is because transactions committed
may not read version xv created by Tv . Tv should be serialized after (1) PrewriteSet (Tv ) ∩ ReadSet (Ts ) 6= ∅ and Priority(Tv ) ≥ Priority
all transactions committed that read data item x. (Ts ). The serialization order between Ts and Tv is adjusted such
The algorithm of local final backward validation is described as that Ts → Tv . That is, Ts precedes Tv in the serialization order.
the following. It implies that the read of Ts is placed before the write of Tv
although Tv is committed beforeTs . The adjustment of VI (Ts )
local_final_backward_validation(Tv ) { should be: VI ub (Ts ) < TS (Tv ). That is, set VI (Ts ) = VI (Ts ) ∩
for each xk in ReadSet (Tv ) { [0, VI lb (Tv )].
if (xk is not marked as valid) { (2) PrewriteSet (Tv ) ∩ ReadSet (Ts ) 6= ∅ and Priority(Tv ) < Priority
if (Ts ), and Ts does not miss its deadline if restarted. The
(∃xk+1 (xk xk+1 ))VI (Tv ) = VI (Tv ) ∩ [0, WTS (xk+1 )]; serialization order between Ts and Tv is adjusted such that
if (VI (Tv ) == []) { Ts → Tv . That is, Ts precedes Tv in the serialization order.
abort Tv ; It implies that the read of Ts is placed before the write of Tv
AbortSet = AbortSet ∪ {Tv }; although Tv is committed before Ts . The adjustment of VI (Ts )
} should be: VI ub (Ts ) < TS (Tv ). That is, set VI (Ts ) = VI (Ts ) ∩
} [0, VI lb (Tv )].
} (3) PrewriteSet (Tv ) ∩ ReadSet (Ts ) 6= ∅ and Priority(Tv ) < Priority
for each xv in PrewriteSet (Tv ) { (Ts ), and Ts may miss its deadline if restarted, Tv is restarted.
VI (Tv ) = VI (Tv ) ∩ [max(RTS (x)), ∞];
if (VI (Tv ) == []) { For each of the active transactions Ts in the conflict set of Tv ,
abort Tv ; ConflictSet (Tv ), if the version xv of data item x is in PrewriteSet (Tv ),
AbortSet = AbortSet ∪ {Tv }; the version xk of data item x in ReadSet (Ts ) and the priority of
} Tv greater than or equal to the priority of Ts , then the adjust-
} ment of VI (Ts ) should be: VI ub (Ts ) < TS (Tv ). That is, set VI (Ts ) =
} VI (Ts ) ∩ [0, VI lb (Tv )]. If the priority y of Tv is less than that of
Ts , and Ts does not miss its deadline if restarted, then the adjust-
At the server a validating transaction may be a server transac- ment of VI (Ts ) should be: VI ub (Ts ) < TS (Tv ). That is, set VI (Ts ) =
tion or mobile transaction submitted by the MHs. It is not desirable VI (Ts ) ∩ [0, VI lb (Tv )]. If Ts ’s validation interval is empty, it must be
to restart a validating transaction, in particular, a mobile transac- restarted. If the priority of Tv is less than that of Ts , and Ts may miss
tion because of the high cost to restart a mobile transaction. There- its deadline if restarted, Tv is restarted. If Tv is a local transaction
fore, forward validation is better choice for the server because and is allowed to be committed, a final timestamp indicating its
of the flexibility. In real-time mobile applications, data conflicts position in the serialization order is assigned to it. The final times-
should be resolved in favor of higher priority transactions. Forward tamp TS (Tv ) is equal to min(CurrentTime, VI lb (Tv ) + 1), where 1
validation provides flexibility for conflict resolution that either val- is a sufficiently small value. If a transaction is never adjusted, the
idating transaction or the conflicting active transactions may be final timestamp of Tv is the current system time. The read and the
chosen to restart, so it is preferable for real-time mobile database write set of Tv are added into CT_ReadSet and CT_WriteSet accord-
systems. In addition to this flexibility, forward validation has the ingly. When the next broadcast cycle comes, the server broadcasts
advantage of early detection and resolution of data conflicts. Let the validation information. If Tv is a distributed transaction, Tv is
the server active transaction conflict set of Tv be ConflictSet (Tv ). If submitted to the coordinator for global validation.
the priority of mobile transaction Tv is higher than of that conflict- The algorithm of local forward validation is described as the
ing server active transaction Ts , VI (Ts ) is adjusted. If the priority of following.
872 X. Lei et al. / J. Parallel Distrib. Comput. 69 (2009) 866–876
types on data item x. Let ri [xk ] represent the read operation of (2) Both transactions Ti and Ti+1 are global transactions. Then by
Ti reading the versionxk of x, and wi [xi ] denote Ti writes a version xi Lemma 1, there exists TS (T1 ) < TS (Ti ) < TS (Ti+1 ) < TS (T1 ) at
of x. least one site. This is a contradiction and therefore no cycle can
Case 1: ri [xk ] → wj [xj ] exist.
Two possible cases of commit order have to be considered. Therefore, by Lemma 1, TS (T1 ) < TS (T2 ) < TS (Td2 ) < TS (Tk )
(1) Ti is committed before Tj reaches the validation phase. < TS (Td1 ) < · · · < TS (Tn ) < TS (T1 ). Therefore, by induction,
For wj [xj ], when Tj reaches the validation phase, the TS (T1 ) < TS (T1 ). This is a contradiction. Therefore no cycle
validation interval of Tj will be adjusted: VI (Tj ) = VI (Tj ) ∩ can exist in MVSG(GH , ) and thus the DMVOCC-2PLV protocol
[WTS (xk ), ∞] ∩ [RTS (xk ), ∞], where xk is the version of x produces only globally serializable histories.
whose write timestamp is the largest write timestamp less
than or equal to TS (Tj ). At the server the adjustment of VI (Tj ) 6. Performance evaluation
should be VI lb (Tj ) > max(RTS (x)). That is, set VI (Tj ) = VI (Tj ) ∩
[max(RTS (x)), ∞]. This ensures that the final timestamp of Tj , The simulation experiments are aimed at studying the per-
TS (Tj ), which is obtained by adding a sufficiently small value formance of the proposed new concurrency control method
to the lower bound of VI (Tj ), is greater than RTS (xk ), which (DMVOCC-2PLV), PVTO-2PC (PVTO [11] combined with 2PC), and
is equal to or greater than TS (Ti ). Thus, TS (Ti ) ≤ RTS (xk ) < DHP-2PL [8] in real-time broadcast environments. The major per-
TS (Tj ). Therefore, TS (Ti ) < TS (Tj ). formance of these protocols is the miss rate. Other performance
(2) Tj is committed before Ti reaches a validation phase. metrics includes restart rate, commit rate. The formulas of the per-
When Ti reaches the validation phase, for ri [xk ], the formance measures are listed below.
validation interval of Ti will be adjusted: VI (Ti ) = VI (Ti ) ∩ Number of transactions missing their deadline
Miss rate =
[0, WTS (xk )], where WTS (xk ) is equal to TS (Tj ). At the server Total number of transactions
if there exists version xk+1 , xk xk+1 , the adjustment of Number of transactions restarted
VI (Ti ) should be VI ub (Ti ) < WTS (xk+1 ). That is, set VI (Ti ) = Restart rate =
Total number of transactions
VI (Ti ) ∩ [0, WTS (xk+1 )]. This ensures that TS (Ti ) is smaller than
Number of transactions committed
WTS (xk ). Thus, TS (Ti ) < WTS (xk ) = TS (Tj ). Therefore, TS (Ti ) < Commit rate = .
TS (Tj ). Total number of transactions
PVTO (Partial Validation and Timestamp Ordering) protocol
Case 2 : wi [xi ] → rj [xi ] is a single-version optimistic concurrency control protocol based
This case happens when Ti is committed before Tj reads xi . on timestamp ordering mechanism. The protocol detects data
When Tj reads xi , the validation interval of Tj will be adjusted: conflicts at an early stage at the MHs and resolves data conflicts
VI (Tj ) = VI (Tj ) ∩ [WTS (xi ), ∞], where WTS (xi ) is equal to TS (Tj ). flexibly using a dynamic adjustment serializability order. The DHP-
This ensures that TS (Tj ) is greater than WTS (xi ). Thus, TS (Ti ) = 2PL (Distributed High Priority Two Phase Locking) protocol is a
WTS (xi ) < TS (Tj ). Therefore, TS (Ti ) < TS (Tj ). distributed real-time locking protocol based on a high priority
two phase locking (HP-2PL) scheme, where the characteristics of
Theorem 1. Every MV local history (LH) generated by the DMVOCC- the mobile network are considered in resolving the conflicts in
2PLV protocol is serializable. data accesses. The protocol attempts to reduce the communication
overhead for processing transactions by a transaction shipping
Proof. Assume that in the MVSG(LH , ) generated by DMVOCC-
approach.
2PLV protocol, there exists a cycle T1 → T2 → T3 → · · · →
In order to evaluate the performance of various algorithms,
Tn → T1 . Using the results of Lemma 1, this implies TS (T1 ) <
we develop a simulation model based on the simulation tools
TS (T2 ) < · · · < TS (Tn ) < TS (T1 ). This results in an irresolvable
OPNET [15]. It consists of MHs, MSSs and Servers. The simulation
contradiction. Thus, MVSG(LH , ) must be acyclic, implying that
program was written in a C++. With each data item x, the
the schedule must be serializable.
server maintains multiple versions hx1 , x2 , . . . , xm i. Each version
xk contains three data fields: the value of versions xk , WTS (xk ),
Theorem 2. Every MV global history (GH) generated by the
RTS (xk ). The broadcast medium is modeled as a broadcast disk
DMVOCC-2PLV protocol is serializable.
with different speeds of rotation. The server broadcasts multiple
Proof. Suppose that MVSG(GH , ) generated by DMVOCC-2PLV versions for each data item to MHs periodically. The data items
protocol contains a cycle T1 → T2 → T3 → · · · → Tn → T1 , of the broadcast are divided in the ranges of similar access
where n > 1. For n = 2, there are two possible cases: probabilities. Each of these ranges is placed on a separate disk.
Case 1: Both transactions are local transactions. Then by Older versions of host items are placed along with the current
Theorem 1 we have TS (T1 ) < TS (T1 ). This is a contradiction and values of hot items on the fast disks, while versions of cold data
therefore no cycle can exist. are placed on slow disks. We assume a broadcast disk organization
Case 2: Both transactions are global transactions. Because the with three disks and relative frequencies 5, 3, and 1. Every
proposed protocol executes global operations in both sites, thus broadcast cycle is subdivided into 5 minor cycles. The broadcast
the serialization graphs for both sites are identical. Therefore, by bandwidth is 128000 bits/s. The server has a database of 500 data
Theorem 1 we have TS (T1 ) < TS (T1 ). This is a contradiction and items and the size of each data item is 6400 bits. The data items that
therefore no cycle can exist. a transaction accesses are uniformly distributed in the database.
Suppose that the Theorem 2 holds for n = i for i ≥ 2. It will be At the beginning of every broadcast cycle, the server fills the
shown that it holds for n = i + 1. By the induction hypothesis, the broadcast disk with all the data items in the database along with
path T1 → · · · → Ti implies that TS (T1 ) < TS (Ti ). By Ti → Ti+1 the validation information of the committed transactions in the
there are two possible cases to be considered. last broadcast cycle. After the completion of a transaction, MH will
generate another transaction after a think time. The deadline of
(1) Both transactions Ti and Ti+1 are local transactions. Then by transaction T is assigned as the following formula:
Lemma 1, there exists TS (T1 ) < TS (Ti ) < TS (Ti+1 ) < TS (T1 )
at least one site. This is a contradiction and therefore no cycle Deadline(T ) = Slackfactor × PredictedExecutionTime(T )
can exist. + ArrivalTime(T )
874 X. Lei et al. / J. Parallel Distrib. Comput. 69 (2009) 866–876
7. Conclusions
at two phases: local pre-validation and local final validation. [12] GuoQiong Liao, YunSheng Liu, LiNa Wang, Concurrency control of real-time
At the MHs, all mobile transactions perform a local backward transactions with disconnections in mobile computing environment, in: Proc.
of the 2003 International Conference on Computer Networks and Mobile
pre-validation of transactions. The local pre-validation process is Computing, ICCNMC’03, 2003, pp. 205–212.
carried out against committed transactions at the server. Such [13] Jan Lindström, Performance of distributed optimistic concurrency control
an early data conflict detection feature can save processing and in real-time databases, in: Proc. of the 17th International Conference
on Information Technology, CIT’04, in: LNCS, vol. 3365, Springer, 2004,
communication resources. In global validation distributed update pp. 243–252.
transactions have to do checks to ensure distributed serializability [14] Guohui Li, Bing Yang, Jixiong Chen, Efficient optimistic concurrency control for
in all participants. The MHs do not need to synchronize with mobile real-time transactions in a wireless data broadcast environment, in:
Proc. of the 11th IEEE International Conference on Embedded and Real-Time
each other and servers for data conflict detection. The protocol Computing Systems and Applications, RTCSA’05, 2005, pp. 443–446.
can eliminate conflicts between mobile read-only and mobile [15] OPNET Modeler/Radio ©, OPNET Technologies Inc., http://www.opnet.com.
update transactions, and resolve data conflicts flexibly using a [16] Chanjung Park, Seog Park, Sang H. Son, Multiversion locking protocol
with freezing for secure real-time database systems, IEEE Transactions on
multiversion dynamic adjustment of serialization order to avoid
Knowledge and Data Engineering 5 (14) (2002) 1141–1154.
unnecessary restarts of transactions. For a mobile ready-only [17] E. Pitoura, P.K. Chrysanthis, Scalable processing of read-only transactions
transaction, it can be committed locally at the MH if it passes in broadcast push, in: Proc. of the 19th IEEE International Conference on
all the local pre-validations in the course of its execution. The Distributed Computing System, 1999, pp. 432–439.
[18] E. Pitoura, P.K. Chrysanthis, Multiversion data broadcast, IEEE Transactions on
respond time of mobile read-only transactions is greatly reduced. Computers 51 (10) (2002) 1224–1230.
The tolerance of mobile transactions of disconnections from the [19] D.J. Ram, M.A.M. Mohamed, V.R. Devanathan, A framework for concurrency
broadcast channel is increased. The correctness of the DMVOCC- control in real-time distributed collaboration for mobile systems, in: Proc.
of the 23rd International Conference on Distributed Computing Systems
2PLV protocol is proved. That is, the DMVOCC-2PLV protocol Workshops, ICDCSW’03, 2003, pp. 488–492.
ensures serializability. The results of simulation experiments show [20] Abraham Silberschatz, Henry F. Korth, S. Sudarshan, Database System
that the new protocol proposed offers better performance in terms Concepts, third edition, McGraw-Hill, New York, 1999.
of miss rate, restart rate, commit rate and throughput.
Lei Xiangdong received the Ph.D. degree in computer
Acknowledgment science from Central South University in 2008. He is
now an associate professor at School of Information Sci-
ence and Engineering, Central South University. His cur-
This work has been supported by the National Research rent research interests include mobile database, parallel
Foundation for the Doctoral Program of Higher Education of China database, real-time database technique, etc.
(No. 20030533011).
References