A Critique of the Proposed National Education Policy Reform
Concurrency of Issues of Distributed Advance Transaction
1. CONCURRENCY
Concurrency of Issues of Distributed
Advance Transaction
Presented by : ABDEL-HAFIZ AHMAD KHOUDOUR
Email : abdelhafiiz@yahoo.com
2. Concurrency Control
when several transaction execute
concurrently in the database The
fundamental properties of the transaction
is isolation.
The system must control the interaction
among the concurrent transaction.
3. The control achieved through one of a
variety of mechanism called concurrency
control schemes .
This concurrency – control schemes based
on the serializability property .
4. Lock based Protocol
A locking protocol is a set of rules that
state when a transaction may lock and
unlock .
To ensure serializability is to require that
data items be accessed in mutually
exclusive manner.
5. While one transaction is accessing a data
item, no other transaction can modify that
data.
The most common method used to
implement requirements is to allow a
transaction to access data item only if it is
currently holding a lock on that item.
6. Two modes of data item may be locked
Shared-mode (s) lock.
Executive-mode (X) lock
Lock compatibility matrix
S X
S true false
X false false
7. • Shared mode is compatible with shared mode,
several shared mode lock can be held at the
same time on a particular data item .
• Every transaction request a lock depending on
the types of operations.
8. • A transaction will make by the concurrency –
control manager.
• Both of the transaction and the operation
continue after the concurrency-manager
grants the lock to the transaction.
9. Granting of Locks
The concurrency-control manager grants the lock
provided :
• If there is no other transaction holding a lock in
a conflicting mode.
• Also if there is no other transaction that is
waiting for a lock .
• A lock request made later will never get blocked
a lock request.
10. Implementation of locking
• Receive messages from transaction and sends
messages in reply.
• Replay to lock-request messages with lock-grants
messages.
• Unlock-messages require only and acknowledgment
In response, but may result in a grant messages to
another waiting transaction.
11. Graph-Based Protocols
• It impose restrictions on the order in which items are
accessed.
• in that way we can ensure serializability without
requiring of two-phase locking and can also ensure
deadlock freedom.
12. Timestamp – Based Protocols
• A method that to select an ordering among
transaction in advance.
• The most common method for doing so is to use a
timestamp-ordering scheme
13. Timestamps
The timestamp of the transactions determine the
serializability order.
There are two simple methods for implementing
this scheme:
1. Use the value of the system clock as the
timestamp, a transaction’s timestamp is equal
to the value of the clock when the transaction
enters the system.
14. Use a logical counter : is incremented when after a new
timestamp has been assigned
We can associate with each data items two values
W-timestamp
R-timestamp
15. Weak level of consistency
Serializability is a useful concept because it allows
programmers to ignore issues related to concurrency
when they code transaction.
For example SQL allows a transaction to specify that it
may executed in a way that becomes nonserializable
with respect to other transaction .