0% found this document useful (0 votes)
13 views38 pages

Lec 3

Uploaded by

hghauri30
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PPTX, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
13 views38 pages

Lec 3

Uploaded by

hghauri30
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PPTX, PDF, TXT or read online on Scribd
You are on page 1/ 38

Database Architectures

and the Web


Chapter 3
Multi-user Database System Architectures
• 3.1.1 Teleprocessing
• 3.1.2 File-Server Architecture
• 3.1.3 Traditional Two-Tier Client–Server Architecture
• 3.1.4 Three-Tier Client–Server Architecture
• 3.1.5 N-Tier Architectures
• 3.1.6 Middleware
• 3.1.7 Transaction Processing Monitors
1. Teleprocessing

• The traditional architecture for multi-user systems was teleprocessing


• One computer with a single central processing unit (CPU)
• And a number of terminals
• All processing is performed within the boundaries of the same
physical computer
• User terminals are typically incapable of functioning on their own,
and cabled to the central computer
• The terminals send messages via the communications control
subsystem of the operating system to the user’s application program
• Which in turn uses the services of the DBMS
• In the same way, messages are routed back to the user’s terminal.
• Tremendous burden on the central computer,
• Which had to not only run the application programs and the DBMS,
but also carry out a significant amount of work on behalf of the
terminals (such as formatting data for display on the screen).
• In recent years, there have been significant advances in the
development of high-performance personal computers and networks.
• Replacing expensive mainframe computers with more cost-effective
networks of personal computers that achieve the same, or even
better, results.
• This trend has given rise to the next two architectures: file-server and
client-server.
2. File-Server Architecture
• File server
• A computer attached to a network with the primary purpose of
providing shared storage for computer files such as documents,
spreadsheets, images, and databases.
• In a file-server environment, the processing is distributed about the
network, typically a local area network (LAN).
• The file-server holds the files required by the applications and the
DBMS.
• However, the applications and the DBMS run on each workstation,
requesting files from the file-server when necessary.
• In this way, the file-server acts simply as a shared hard disk drive
• The DBMS on each workstation sends requests to the file-server for
all data that the DBMS requires that is stored on disk
• Significant amount of network traffic, which can lead to performance
problems
• SELECT fName, Iname FROM Branch b, Staff s
WHERE b.branchNo = s.branchNo AND b.street = ‘163 Main St’;
• As the file-server has no knowledge of SQL, the DBMS must request
the files corresponding to the Branch and Staff relations from the file-
server, rather than just the staff names that satisfy the query.
Disadvantage
• Three main disadvantages:
(1) There is a large amount of network traffic.
(2) A full copy of the DBMS is required on each workstation.
(3) Concurrency, recovery, and integrity control are more
complex, because there can be multiple DBMSs accessing the
same files.
3. Traditional Two-Tier Client–Server
Architecture
• The client–server architecture was developed
• To overcome the disadvantages of the first two approaches
• Accommodate an increasingly decentralized business environment,
• There is no requirement that the client and server must reside on the
same machine
• In practice, it is quite common to place a server at one site in a LAN
and the clients at the other sites
• Data-intensive business applications consist of four major
components:
• The database,
• The transaction logic,
• The business and data application logic,
• The user interface
Traditional two tier client-server architecture
Three-Tier Client–Server Architecture
• Problems with previous architecture
• A “fat” client, requiring considerable resources on the client’s computer
to run effectively. This includes disk space, RAM, and CPU power.
• A significant client-side administration overhead.
• New Architecture proposed three layers:
• The user interface layer, which runs on the end-user’s computer (the
client).
• (2) The business logic and data processing layer. This middle tier runs on
a server and is often called the application server.
• (3) A DBMS, which stores the data required by the middle tier. This tier
may run on a separate server called the database server.
N-Tier Architectures
• The three-tier architecture can be expanded to n tiers
• Application servers
• Hosts an application programming interface (API) to expose business
logic and business processes for use by other applications.
Distributed Database Systems
• Distributed database
• A logically interrelated collection of shared data (and a description
of this data), physically distributed over a computer network.
• Distributed DBMS
• The software system that permits the management of the
distributed database and makes the distribution transparent to
users.
Distributed DBMSs
• Decentralized approach
• Single logical database
• Split into a number of fragments
• Each fragment is stored on one or more computers (replicas)
• Use computer network to access data
• Local Autonomy
• Local applications for local data access
• Global Application for Global data access
• A collection of logically related shared data;
• Data split into a number of fragments;
• Fragments may be replicated;
• Fragments/replicas are allocated to sites;
• Sites are linked by a communications network;
• Data at each site is under the control of a DBMS;
• DBMS at each site can handle local applications, autonomously;
• Each DBMS participates in at least one global application.
IT Systems
We can divide IT systems into further two systems
1. Online Transaction Processing System
(OLTP)
2. Online Analytical Processing System
(OLAP).

- In general we can assume that OLTP systems provide source data to


data warehouses, whereas OLAP systems help to analyze it.
OLTP Systems (Online Transaction Processing System)

• To automate business process


• Efficient and cost-effective services to the customer
• Use operational data to support decision making
• For gaining competitive advantages
• Operational systems were never primarily designed to support business
decision making
OLTP (On-line Transaction Processing)
System
• Large number of short on-line transactions (INSERT, UPDATE,
DELETE).
• Fast query processing,
• Maintaining data integrity in multi-access environments and an
effectiveness measured by Number of transactions per second.
• In OLTP database, there is detailed and current data.
• Schema used to store transactional databases is the entity model
(usually 3NF).
OLAP (On-line Analytical Processing)
System
• Relatively low volume of transactions.
• Queries are often very complex and involve aggregations.
• For OLAP systems a response time is an effectiveness measure.
• OLAP applications are widely used by Data Mining techniques.
• In OLAP database there is aggregated, historical data, stored in multi-
dimensional schemas (usually star schema).
Data Warehousing
• The data held in a data warehouse is described as being subject-
oriented, integrated, time-variant, and nonvolatile (Inmon, 1993)
Subject-oriented
• In operational sources data is organized by applications, or business
processes.
• In DW subject is the organization method
• Subjects vary with enterprise
• These are critical factors, that affect performance
• Example of Manufacturing Company
• Sales
• Shipment
• Inventory etc

31
Integrated Data
• Data comes from several applications
• Problems of integration comes into play
• File layout, encoding, field names, systems, schema, data heterogeneity are
the issues
• Bank example, variance: naming convention, attributes for data item, account
no, account type, size, currency
• In addition to internal, external data sources
• External companies data sharing
• Websites
• Others
• Removal of inconsistency
• So process of extraction, transformation & loading

32
Time variant
• Operational data has current values
• Comparative analysis is one of the best techniques for business
performance evaluation
• Time is critical factor for comparative analysis
• Every data structure in DW contains time element
• In order to promote product in certain, analyst has to know about current
and historical values
• The advantages are
• Allows for analysis of the past
• Relates information to the present
• Enables forecasts for the future

33
Non-volatile
• Data from operational systems are moved into DW after specific intervals
• Data is persistent/ not removed i.e. non volatile
• Every business transaction don’t update in DW
• Data from DW is not deleted
• Data is neither changed by individual transactions
• Properties summary

Subject Oriented Time-Variant Non-Volatile

Organized along the lines of Every record in the data Refers to the inability of data
the subjects of the to be updated. Every record
warehouse has some
corporation. Typical subjects in the data warehouse is
are customer, product, form of time variancy time stamped in one form or
vendor and transaction. attached to it. another.

34
OLTP System OLAP System
Online Transaction Processing Online Analytical Processing
(Operational System) (Data Warehouse)

Consolidation data; OLAP


Operational data; OLTPs are the
Source of data data comes from the various
original source of the data.
OLTP Databases

To help with planning,


To control and run fundamental
Purpose of data problem solving, and
business tasks
decision support

Multi-dimensional views of
Reveals a snapshot of ongoing
What the data various kinds of business
business processes
activities

Short and fast inserts and updates Periodic long-running batch


Inserts and Updates
initiated by end users jobs refresh the data

Relatively standardized and simple


Often complex queries
Queries queries Returning relatively few
involving aggregations
records
OLTP System OLAP System
Online Transaction Processing Online Analytical Processing
(Operational System) (Data Warehouse)

Depends on the amount of data


involved; batch data refreshes and
Processing Speed Typically very fast complex queries may take many hours;
query speed can be improved by
creating indexes

Larger due to the existence of


Can be relatively small if historical data is
Space Requirements aggregation structures and history data;
archived
requires more indexes than OLTP

Typically de-normalized with fewer


Database Design Highly normalized with many tables tables; use of star and/or snowflake
schemas

Instead of regular backups, some


Backup religiously; operational data is critical to
environments may consider simply
Backup and Recovery run the business, data loss is likely to entail
reloading the OLTP data as a recovery
significant monetary loss and legal liability
method
The typical architecture of a data warehouse.

You might also like