Distributed Database System And: Transaction-Processing

Download as pptx, pdf, or txt
Download as pptx, pdf, or txt
You are on page 1of 21

Distributed Database system

and Transaction-Processing

Complied by muluken ashagre


Learning Objectives

• At the end of this topic the student should be able to


 Define Distributed dbs
 Identify types Distributed dbs
 Know advantages of Distributed dbs
 Know transaction processing system

Complied by muluken ashagre


What is distributed database
• A distributed database (DDB) is a collection of
multiple, logically interrelated databases
distributed over a computer network.
• They provide a mechanism that makes the
distribution of data transparent to users
• A distributed database management system
(D–DBMS) is the software that manages the
DDB and provides an access mechanism that
makes this distribution transparent to the users.
Distributed DBMS

5
Advantages of DDBMSs
• Organizational Structure
• Share ability and Local Autonomy
• Improved Availability
• Improved Reliability
• Improved Performance
• Economics
Disadvantages of DDBMSs
• Complexity
• Cost
• Security
• Integrity Control More Difficult
• Lack of Standards
• Lack of Experience
• Database Design More Complex
Types of DDBMS
Distributed databases can be broadly classified into
Homogeneous DDBMS
Heterogeneous DDBMS
Homogeneous Distributed Databases
In a homogeneous distributed database, all the sites use
identical DBMS and operating systems.
Its properties are –
• The sites use very similar software.
• The sites use identical DBMS or DBMS from the same
vendor.
• Each site is aware of all other sites and cooperates with
other sites to process user requests.
• The database is accessed through a single interface as if
it is a single database
Types of Homogeneous Distributed Database

• There are two types of homogeneous distributed


database −
• Autonomous − Each database is independent that
functions on its own. They are integrated by a
controlling application and use message passing to
share data updates.
• Non-autonomous − Data is distributed across the
homogeneous nodes and a central or master DBMS
co-ordinates data updates across the sites.
Heterogeneous Distributed Databases
In a heterogeneous distributed database, different sites have
different operating systems, DBMS products and data models.
Its properties are −
• Different sites use dissimilar schemas and software.
• The system may be composed of a variety of DBMSs like
relational, network, hierarchical or object oriented.
• Query processing is complex due to dissimilar schemas.
• Transaction processing is complex due to dissimilar software.
• A site may not be aware of other sites and so there is limited
co-operation in processing user requests.
Types of Heterogeneous Distributed Databases

• Federated − The heterogeneous database systems


are independent in nature and integrated together
so that they function as a single database system.
• Un-federated − The database systems employ a
central coordinating module through which the
databases are accessed.
Features distributed databases :
In general, distributed databases include the following
features:
 Location independent
 Distributed query processing
 Distributed transaction management
 Hardware independent
 Operating system independent
 Network independent
 Transaction transparency
 DBMS independent
Issues with DDBMS
Fragmentation
Relation may be divided into a number of sub-relations,
which are then distributed.
Allocation
Each fragment is stored at site with "optimal" distribution.
Replication
Copy of fragment may be maintained at several sites.
Transaction Processing Systems

• A transaction is an exchange of goods, services,


and/or communication between two sides that has
an effect on each side.
• In the simplest case, a conversation between you
and a friend is a transaction. You exchange
information, and both of you are affected by the
exchange. A
• Transaction processing system is a system that
repeatedly processes various transactions.
The characteristics of Transaction processing system :

• Performance - Transactions are performed as fast


as possible.
• Reliability - Transaction performance occurs like
clockwork.
• Consistency - Transactions are performed in the
same way each and every time.
• Atomic - Transactions are indivisible; once
started, transactions are performed to completion.
Transaction State
1. Active State− In this state, the transaction is being executed.
This is the initial state of every transaction.
2. Partially Committed State− − When a transaction executes
its final operation, it is said to be in a partially committed state.
3. Failed State− − A transaction is said to be in a failed state if
any of the checks made by the database recovery system fails. A
failed transaction can no longer proceed further.
4. Aborted State− − If any of the checks fails and the
transaction has reached a failed state
5. Committed State− − If a transaction executes all its
operations successfully, it is said to be committed. All its effects
are now permanently established on the database system
States of Transactions
What are ACID Properties?
For maintaining the integrity of data, the DBMS system have to
ensure ACID properties.
ACID stands for Atomicity, Consistency, Isolation, and
Durability.
• Atomicity: A transaction is a single unit of operation..
• Consistency: Once the transaction is executed, it should
move from one consistent state to another.
• Isolation: Transaction should be executed in isolation from
other transactions (no Locks).
• Durability: · After successful completion of a transaction, the
changes in the database should persist. Even in the case of
system failures.
Types of Transactions
Based on Application areas

• Non-distributed vs. distributed


• Compensating transactions
• Transactions Timing
• On-line vs. batch
Types of Transactions
Based on Actions

• Two-step
• Restricted
• Action model

You might also like