Distributed Databases. Not just a client/server system. Outline. Concepts Advantages and disadvantages of distributed databases. Functions and architecture for a DDBMS. Distributed database design. Levels of transparency. Comparison criteria for DDBMSs. Distributed.
Not just a client/server system
Database - A logically interrelated collection of shared data (and a description of this data), physically distributed over a computer network.
DBMS - Software system that permits the management of the distributed database and makes the distribution transparent to users.
Relation may be divided into a number of sub-relations, which are then distributed.
Each fragment is stored at site with "optimal" distribution.
Copy of fragment may be maintained at several sites.
CUSTOMER (Cust#, Addr, Location)
Property(propNo, city) 10000 records in London
Client(clientNo,maxPrice) 100000 records in Glasgow
Viewing(propNo, clientNo) 1000000 records in London
FROM Property p INNER JOIN
Client c INNER JOIN Viewing v ON c.clientNo = v.clientNo)
ON p.propNo = v.propNo
WHERE p.city=‘Aberdeen’ AND c.maxPrice > 200000;
0. Fundamental Principle
To the user, a distributed system should look exactly like a nondistributed system.
1. Local Autonomy
2. No Reliance on a Central Site
3. Continuous Operation
4. Location Independence
5. Fragmentation Independence
6. Replication Independence
7. Distributed Query Processing
8. Distributed Transaction Processing
9. Hardware Independence
10. Operating System Independence
11. Network Independence
12. Database Independence
CREATE PUBLIC DATABASE LINK
(1) Read-only snapshots (or materialized views). A master table is copied to one or more remote databases. Changes in the master table are reflected in the snapshot tables whenever snapshot refreshes, as determined by the snapshot site.
(2) Updateable snapshots Similar to read-only snapshots except that the snapshot sites are able to modify data and send their changes back to the master site. Again, snapshot site determines frequency of refreshes and frequency with which updates are sent back to the master site.
(3) Multimaster replication Table is copied to one or more remote databases, where table can be updated. Modifications are pushed to the other database at an interval set by DBA for each replication group.
(4) Procedural replication A call to a packaged procedure or function is replicated to one or more databases.
CREATE SNAPSHOT Staff
START WITH sysdate NEXT sysdate + 7
WITH PRIMARY KEY
AS SELECT *
FROM Staff@RENTALS.LONDON.SOUTH.COM WHERE branchNo = ‘B003’;