20
3-Tier Architecture 3-Tier Architecture Prepared By Channu Kambalyal Page 1 of 19

NTierArchitecture

Embed Size (px)

Citation preview

8/6/2019 NTierArchitecture

http://slidepdf.com/reader/full/ntierarchitecture 1/19

3-Tier Architecture

3-Tier Architecture

Prepared By

Channu Kambalyal

Page 1 of 19

8/6/2019 NTierArchitecture

http://slidepdf.com/reader/full/ntierarchitecture 2/19

3-Tier Architecture

Table of Contents

1.0 Traditional Host Systems........................................................................................ 32.0 Distributed Systems................................................................................................4

3.0 Client/Server Model ................................................................................................54.0 Distributed Client/Server Model .............................................................................. 65.0 Inter-process Communication................................................................................. 76.0 Benefits of the Client/Server Model ........................................................................87.0 Client/Server 2-Tier Architecture ............................................................................98.0 3-Tier Client/Server Architecture ..........................................................................119.0 Middleware ........................................................................................................... 1310.0 Architectures in Discover Financial Services...................................................... 14

10.1 Current DAS Architecture................................................................................ 1410.2 Migration from DAS-Tuxedo based to J2EE - WebSphere based system ...... 1510.3 Future WebSphere Based System.................................................................. 16

11.0 Architecture Trends ............................................................................................ 1711.1 Web Services, J2EE Connectors, Message Brokers, etc................................ 1711.2 Business Process Management (BPM)........................................................... 19

Page 2 of 19

8/6/2019 NTierArchitecture

http://slidepdf.com/reader/full/ntierarchitecture 3/19

3-Tier Architecture

1.0 Traditional Host Systems

 A Central Processing System (Mainframe) provides all processing.

Local Terminals are responsible for display and keyboard for user input and viewing

capabilities. Local Terminals do not contain any intelligent processing capabilities.

Mainframe

Computer 

Keyboard

Computer 

Keyboard

Computer 

Keyboard

 

Figure 1.0.1 Non-Client-Server System

File Server and retrieval processing provided by File Server 

Word Processing and spreadsheet processing provided by PC workstation.

Mainframe

Computer 

Keyboard

Computer 

Keyboard

Computer 

Keyboard

Server 

Server 

Computer 

Keyboard

 

Figure 1.0.2 Traditional Host System with LAN

Page 3 of 19

8/6/2019 NTierArchitecture

http://slidepdf.com/reader/full/ntierarchitecture 4/19

3-Tier Architecture

2.0 Distributed Systems

Distributed System

Both data and transaction processing are divided between one or more computersconnected by a network, each computer playing a specific role in the system.

Replication

Ensures data at all sites in a distributed system reflects any changes made anywherein the system.

Computer 

Computer 

Computer 

Computer 

Computer 

Computer 

Computer 

Computer 

Computer 

Computer 

Computer 

Computer 

server 

Database

server 

Database

Host

Host

D   a  t   a  U   

 p  d   a  t   e  s  

   D  a  t  a

    U  p  d

  a  t  e  s

  R o  u  t  i  n g

   t a  s  k

  s

RoutineTasks

Routine tasks

R  o u  t  i  n e  t  a s k  s 

  R  o  u  t  i  n  g     T  a  s

  k  s

Data Queries

Data Queries

Regional Centers

Corporate Data Centers

Data Replication

 

Figure 1.3. Distributed Data Centers

Page 4 of 19

8/6/2019 NTierArchitecture

http://slidepdf.com/reader/full/ntierarchitecture 5/19

3-Tier Architecture

3.0 Client/Server Model

x Complements distributed systems

x Responds to limitations found in the two host data processing models:

1. The traditional mainframe host model, in which a single mainframeprovides shared data access to many dumb terminals, and;

2. The local area network (LAN) model, in which many isolated systemsaccess a file server that provides no central processing power.

x Provides integration of data and services

x  Application Processing provided by multiple tiers –

1. Database Server 2. Application Server 3. PC Workstation

server 

Database

 Application

Server 

 Application

Services

Computer 

Computer 

Computer 

PC

Workstations

Database retrievel and updating Application Logic GUI presentation

 

Figure 3.1 Client/Server 3-Tier Model

Page 5 of 19

8/6/2019 NTierArchitecture

http://slidepdf.com/reader/full/ntierarchitecture 6/19

3-Tier Architecture

4.0 Distributed Client/Server Model

x  Application processing provided by all tiers of the network –

1. Mainframe2. Application Servers3. Workstations

x Multiple databases to support distributed data requirements

x Supports high volume, load balancing and scalability (extendibility)

x Requires extensive network administration and application management.

 Application

Server 

Computer 

Computer 

Computer 

PC

Workstations

Database retrievel

and updating

 Application LogicGUI

presentation

Computer 

Computer 

Computer 

PC

Workstations Application

Server 

 Application

Server 

Computer 

Computer 

Computer 

PC

Workstations

Mainframe

Database

Datab

ase

 

Figure 4.1 Distributed Client/Server Model

Page 6 of 19

8/6/2019 NTierArchitecture

http://slidepdf.com/reader/full/ntierarchitecture 7/19

3-Tier Architecture

5.0 Inter-process Communication

x Basis for client/server computing

x

Client process communicates with server processx Each process performs separate functions

x Data is passed between processes using IPC functions

Server ProcessClient Process

Relational

Database

Get input from

user 

Request

processing from

server 

Receive request

for processing

Retreive and

process data

Return values

Receive returned

values

Display output to

user 

In ter-process

Communica tion

Pipes

FIFOs

Message Queues

Semaphores

Shared MemorySockets

Streams

 

Figure 5.1 Inter-Process Communication

Page 7 of 19

8/6/2019 NTierArchitecture

http://slidepdf.com/reader/full/ntierarchitecture 8/19

3-Tier Architecture

6.0 Benefits of the Client/Server Model

x Divides Application Processing across multiple machines:

¾Non-critical data and functions are processed on the client

¾Critical functions are processed on the server 

x Optimizes Client Workstations for data input and presentation (e.g., graphicsand mouse support)

x Optimizes the Server for data processing and storage (e.g., large amount of memory and disk space)

x Scales Horizontally – Multiple servers, each server having capabilities andprocessing power, can be added to distribute processing load.

x Scales Vertically - Can be moved to more powerful machines, such asminicomputer or a mainframe to take advantage of the larger system’sperformance

x Reduces Data Replication - Data stored on the servers instead of each client,reducing the amount of data replication for the application.

Page 8 of 19

8/6/2019 NTierArchitecture

http://slidepdf.com/reader/full/ntierarchitecture 9/19

3-Tier Architecture

7.0 Client/Server 2-Tier Architecture

Two-tier client/server architectures have 2 essential components

1. A Client PC and2. A Database Server 

2-Tier Considerations:

x Client program accesses database directly

o Requires a code change to port to a different databaseo Potential bottleneck for data requestso High volume of traffic due to data shipping

x Client program executes application logico Limited by processing capability of client workstation (memory, CPU)o Requires application code to be distributed to each client workstation

Server Machine

Client Workstation

Client Program

GUI presentation

logic

database request

File Access

Routines

Client Workstation

Client Program

GUI presentation

logic

database request

File Access

Routines

Database Management

System

Database Files

D a t  a  r  e q u e s t  e d  D a t  a  r  e t  u r  n e d  

 D a t a  r

 e q u e s t

 e d

 D a t a  r

 e t u r n e

 d

 

Figure 7.1 Client/Server 2-Tier Architecture

Page 9 of 19

8/6/2019 NTierArchitecture

http://slidepdf.com/reader/full/ntierarchitecture 10/19

3-Tier Architecture

Two – Tier Pros and Cons

Advantages Disadvantages

Development Issues:

x Simple structure

x Easy to setup and maintain

Development Issues:

x Complex application rules difficult to

implement in database server – requiresmore code for the client

x Complex application rules difficult toimplement in client and have poor performance

x Changes to business logic notautomatically enforced by a server –changes require new client side softwareto be distributed and installed

x Not portable to other database server platforms

Performance:x  Adequate performance for low to medium

volume environments

x Business logic and database arephysically close, which provides higher performance.

Performance:x Inadequate performance for medium to

high volume environments, sincedatabase server is required to performbusiness logic. This slows down databaseoperations on database server.

Page 10 of 19

8/6/2019 NTierArchitecture

http://slidepdf.com/reader/full/ntierarchitecture 11/19

3-Tier Architecture

8.0 3-Tier Client/Server Architecture

3-Tier client-server architectures have 3 essential components:

1. A Client PC2. An Application Server 3. A Database Server 

3-Tier Architecture Considerations:

x Client program contains presentation logic onlyo Less resources needed for client workstationo No client modification if database location changeso Less code to distribute to client workstations

x One server handles many client requestso More resources available for server programo Reduces data traffic on the network

Client Workstation

Server Machine

Client Program

GUI presentation

Requests for aplication

function

Communication

Functions

Server Program

 Application Logic

Database Requests

Communication

Functions

Server Machine

Database

Management

System

Database

File

 

Figure 1.8. Typical 3 – Tier Architecture

Page 11 of 19

8/6/2019 NTierArchitecture

http://slidepdf.com/reader/full/ntierarchitecture 12/19

3-Tier Architecture

3 – Tier Pros and Cons 

Advantages Disadvantages

Development Issues:x Complex application rules easy to

implement in application server 

x Business logic off-loaded from databaseserver and client, which improvesperformance

x Changes to business logic automaticallyenforced by server – changes require onlynew application server software to beinstalled

x  Application server logic is portable toother database server platforms by virtueof the application software

Development Issues:x More complex structure

x More difficult to setup and maintain.

Performance:

x Superior performance for medium to highvolume environments

Performance:

x The physical separation of applicationservers containing business logicfunctions and database servers containingdatabases may moderately affectperformance.

Page 12 of 19

8/6/2019 NTierArchitecture

http://slidepdf.com/reader/full/ntierarchitecture 13/19

3-Tier Architecture

9.0 Middleware

Simplifies 3-tier application development and administration by providing an extra application server layer to manage communication between components.

Middleware Characteristics:

o Simplifies partitioning of application processing among clients and serverso Manages distributed transactions among multiple databaseso Communicates with heterogeneous database products within a single application.o Supports application scalabilityo Supports service requests prioritization, load-balancing, data dependant routing and queuing.

Client

Application

Client-Side

Middelware

Server-Side

Middleware

Application

Servers

Cimmunication

(IPC)

Relational

Database

Client

Server 

 

Figure 1.9 Middleware

Page 13 of 19

8/6/2019 NTierArchitecture

http://slidepdf.com/reader/full/ntierarchitecture 14/19

3-Tier Architecture

10.0 Architectures in Discover Financial Services

10.1 Current DAS Architecture

TUXEDO DOMAIN in 7 Centers

 AIX - Tuxedo Based Application Server 

Database Appl.

Svc.(Req.

Routers)

Java Clients

 About 500 to 4000

PC Clients in 7centers

GUI presentation & most of the App Logic

 AIX - Tuxedo Based Application Server 

GtwaySvc

Mainframe

CORBA

Servers(Tuxedo-Client)

SNA over TCP/IP

Partial Application Logic

Primary

DatabaseinRiverwoods

UOWMgr Svc

Java Clients

Java Clients

 I I O P

BATCHProcesses

 Fig. 10.1 Current DAS Architecture

Key Features:

1. DAS – built on DCE-RPC based BEA Tuxedo Middleware (C based) 2. Clients to Tuxedo based on CORBA based Visibroker (C++/Java based) 3. Java based client applications using IIOP for Corba4. Mainframe connectivity uses SNA over TCP/IP

Page 14 of 19

8/6/2019 NTierArchitecture

http://slidepdf.com/reader/full/ntierarchitecture 15/19

3-Tier Architecture

10.2 Migration from DAS-Tuxedo based to J2EE - WebSphere based system

Dist. Batch Server 

TUXEDO DOMAIN in 7 Centers

 AIX - Tuxedo Based Application Server 

Database Appl.

Svc.

(Req.

Routers)

Java Clients

 About 500 to 4000

PC Clients in 7

centers

GUI presentation & most of the App Logic

 AIX based

Database Server 

Database

 AIX based WebSphere App.

Servers in 2 centers

EJBs

Partial Application Logic

 AIX - Tuxedo Based Application Server 

GtwaySvc

Mainframe

CORBA

Servers(Tuxedo-

Client)

SNA over TCP/IP

Partial Application Logic

PrimaryDatabaseinRiverwoods

UOW

Mgr 

Svc

Java Clients

Java Clients

I I O P 

BATCH

Processes

JDBC

Batch

ProcessesDB2 Connect

  R  M I  - 

 I I O  P

   D  a   t  a   b  a  s

  e   R  e  p   l   i  c  a   t   i  o  n

WebServices

  S  O A  P

 

Fig. 10.2 Migration from DAS- Tuxedo to WebSphere based system

Current Status:

x Currently out of about 800 TPS about 45% of transaction currently run through DAS andremaining through WebSphere

x Expected date of migration is July/August 2005

Page 15 of 19

8/6/2019 NTierArchitecture

http://slidepdf.com/reader/full/ntierarchitecture 16/19

3-Tier Architecture

10.3 Future WebSphere Based System

Dist. Batch Server 

Java Clients

 About 500 to 4000

PC Clients in 7

centers

GUI presentation & most of the App Logic

 AIX based

Database Server 

in 2 centers

Database

 AIX based WebSphere App.Servers in 2 centers

EJBs

Partial Application Logic

Mainframe

Java Clients

Java Clients

  J   D   B  CBatch

Processes

RMI - IIOP

WebServices

SO AP

 Fig 10.3 Future WebSphere Based 3-Tier Architecture

Key Features:

1. Latest J2EE based client applications using RMI over IIOP 2. Few SOAP based implementations with few Web-Services3. J2EE based WebSphere Application Server  4. DB2 Connect used for Java – Mainframe – DB2 connectivity 

5. JDBC used for Oracle – EJB connectivity and Transaction Management

Page 16 of 19

8/6/2019 NTierArchitecture

http://slidepdf.com/reader/full/ntierarchitecture 17/19

3-Tier Architecture

11.0 Architecture Trends

11.1 Web Services, J2EE Connectors, Message Brokers, etc

Web Services

x  A standardized way of integrating Web-based applications using the XML, SOAP, WSDL andUDDI

x  A means for businesses to communicate with each other and with clients

x  Allow organizations to communicate data without intimate knowledge of each other's ITsystems behind the firewall

x Unlike traditional client/server models, such as a Web server/Web page system, Web servicesdo not provide the user with a GUI. Web services instead share business logic, data andprocesses through a programmatic interface across a network. The applications interface, notthe users. Developers can then add the Web service to a GUI (such as a Web page or anexecutable program) to offer specific functionality to users.

x Different applications from different sources can communicate with each other without time-consuming custom coding, as all communication is in XML, Web services are not tied to anyone operating system or programming language. For example, Java can talk with Perl,Windows applications can talk with UNIX applications

x XML – Extensible Markup Language - Used to tag the data

x SOAP – Simple Object Access Protocol - Used to transfer the data

x WSDL is used for describing the services available

x UDDI - Universal Description, Discovery and Integration - Used to list what services areavailable.

JMS – Java Message Service

x JMS defines the standard for reliable Enterprise Messaging

x Enterprise messaging, often also referred to as Messaging Oriented Middleware (MOM),universally recognized as an essential tool for building enterprise applications

x Provides a reliable, flexible service for the asynchronous exchange of critical business data andevents throughout an enterprise.

x Message-driven beans enable the asynchronous consumption of JMS messages.

x Message sends and receives can participate in Java Transaction API (JTA) transactions.

x J2EE Connector Architecture allows JMS implementations from different vendors to beexternally plugged into a J2EE 1.4 application server.

J2EE Connector Architecture

x The J2EE Connector architecture enables an EIS vendor to provide a standard resourceadapter for its EIS.

x Resource adapter plugs into an application server, providing connectivity between the EIS, theapplication server, and the enterprise application.

x  An EIS vendor needs to provide just one standard resource adapter, which has the capability toplug in to any application server that supports the J2EE Connector architecture.

See diagram of N-Tier Architecture for an overview of all these technologies and how they fit in.

Page 17 of 19

8/6/2019 NTierArchitecture

http://slidepdf.com/reader/full/ntierarchitecture 18/19

3-Tier Architecture

WebSphere Application Server 

Database

Internet Explorer - HTML,

DHTML, Java Applets,

Style Sheets, Java Script

Thin Java Clients

Internet

IBM HTTP Server 

ServletsJSPs

JNDI

Connector 

Framework

EJB Container 

EJB EJB EJB

EJB EJBEJB

J

T

S

Java IDL JDBC JMS

XML Engine

XML Integrators

Connector 

Distributed CORBA

Clients

LEGACY

Systems

Internet Explorer - HTML,

DHTML, Java Applets,

Style Sheets, Java Script

XML

Database

External

Transaction

Systems

Web Service

 

Figure 11.1 Typical N-Tier Architecture using Web Services, JMS, Connectors, CORBA, XMLDatabases, EJB, Servlets, JSP

Page 18 of 19

8/6/2019 NTierArchitecture

http://slidepdf.com/reader/full/ntierarchitecture 19/19

3-Tier Architecture

Page 19 of 19

11.2 Business Process Management (BPM)

x Business Process Management (BPM) enables the integration of diverse applications andhuman participants, as well as the coordinated exchange of information between tradingpartners outside of the enterprise.

x Focuses on Business Process Documentation to Executable!x Further Reference - BPMI.org

Figure 11.2 Typical Business Process Model(Source: WebLogic Workshop Integrator 8.0)