Load Balance
Download
Report
Transcript Load Balance
Oracle9iAS Containers for J2EE
OC4J
Ilkka Ruotsalainen
Senior Sales Consultant
Oracle Finland Oy
Agenda
•
•
Techical Overview of Oracle9iAS
Oracle Java Strategy
–
–
–
–
–
–
–
–
–
•
Intro to Oracle9iAS Containers for J2EE (OC4J)
OC4J Architecture
OC4J J2EE 1.2 Implementation and Features
OC4J JSP Translator
OC4J Servlet Engine
OC4J EJB Container
OC4J Other APIs and Services
OC4J Clustering Services
Oracle Web Cache
Oracle9i Developer Suite
– OC4J Integration with JDeveloper9i
Too Many Incompatible Pieces
RogueWave
Framework
Netscape
Web Server
Novell
Directory
Iona
ORBs
Rational
Modeling
Times Ten
Cache
Microsoft
Database
Actuate
Reporting
Plumtree
Portals
IBM
Application
Server
Borland
Java Tool
Cognos
Analysis
Oracle9iAS = No Assembly Required
Only Oracle9i means no assembly required
Oracle9i
IBM
BEA
Plumtree
Brio/Cognos
phone.com
Vitria
Web Trends
Inktomi
Times Ten
Verisign
Netscape
CA/HP
Borland
Database
Java Server
Enterprise Portal
Bus. Intelligence
Wireless
Integration
Clickstream
Web Cache
Data Cache
Security
Directory
Systems Mgmt.
Java Tools
Oracle9iDB
Oracle9iAS
Oracle9iAS
Oracle9iAS
Oracle9iAS
Oracle9iAS
Oracle9iAS
Oracle9iAS
Oracle9iAS
Oracle9iAS
Oracle9iAS
Oracle9iAS
Oracle9iDS
Oracle Solution:
Complete, Therefore Simple
9iAS
APPLICATION
S E RV E R
9iDB
DATABASE
Complete Server Solution
Oracle9i Database
Object Relational Data
Documents
Files
Multimedia
Any XML Data
APPLICATION
S E RV E R
DATABASE
Messages
Manages All Your Data
Oracle9i Application Server
Transactional Apps
WEB
CACHE
A
P
A
C
H
E
OC4J/J2EE
Portals
Wireless
APPLICATION
S E RV E R
DATABASE
Business Intelligence
Runs All Your Applications
Complete Solution
• Complete solution
Oracle Enterprise
Manager
One View
APPLICATION
S E RV E R
DATABASE
Internet Developer
Suite
The
Platform
One Toolset
Run All Your Web Sites & Applications
Internet
Users
Intranet/
Professional
Users
Servlet / JSP
EJB
Perl Scripting
Portal
PL/SQL
XML / XSL
Oracle
Database
Tables
Files
interMedia
Forms/Servlet
SOAP
LOB
Oracle9i Application Server
• Oracle9iAS can run any web site or application
–
–
–
–
Complete J2EE platform for enterprise Java applications
Develop in Java, PERL, PL/SQL, Forms, XML
Forms Listener Servlet for deployment of Forms in Internet
Reduce costs through a single unified platform for Java,
XML and SQL
XML
The Oracle Java Strategy
• Provide the industry’s most comprehensive Java support
– Full J2EE support, quick to adopt new specification releases
(Middle-Tier)
– Java Stored Procedures, SQLJ, JDBC (RDBMS)
• Provide Enterprise Class J2EE server
– High performance , high scalability, high availability
• Provide integrated productive development tools
– Oracle JDeveloper (Oracle9i Jdeveloper Beta)
– Business Components for Java (BC4J)
• Provide integrated management tools (OEM)
Oracle9iAS Containers for J2EE (OC4J)
• Fully compliant J2EE 1.2 implementation
• Implements major portions of J2EE 1.3
• Pure Java implementation – on top of Standard JDK
• Extremely lightweight – 10MB/15MB
• Provides high performance and scalability
• Cluster support for 24x7
• Productive for developers to use
• Simple to manage and deploy
• Available on Solaris,NT/2000,HPUX,AIX,Tru64,Linux
OC4J and J2EE 1.2/1.3
•
•
OC4J is fully J2EE 1.2
compliant
OC4J implements major
portions of the J2EE 1.3
specifications now
J2EE 1.2
Oracle9iAS
EJB
1.1, partial 2.0
Servlets
2.2, partial 2.3
JSP
1.1
JDBC
2.0
JNDI
1.2
JMS
1.0.1
JTA
1.0.1
JavaMail
1.1.2
Oracle9iAS Containers for J2EE (OC4J)
Using EJBs and J2EE Services - 100% J2EE 1.2 Compliant
JSP 1.1
Servlet (2.2, 2.3)
EJB (1.1, 2.0)
Session, Entity (BMP, CMP)
J2EE Container (1.2, 1.3)
JDK Java VM (1.2, 1.3)
9iAS
JDBC 2.0
RMI
Java Mail 1.1
JNDI 1.2
JMS 1.0
Browser
JTA 1.0
Apache
(9iAS)
Database
Table
Files
MultiMedia
LOB
XML
mod_proxy
HTTP(S)
Apache
OC4J Architecture Diagram
HTTP
HTTP(S)
H
T
T
P
JNDI
Web
Container
Servlet/JSP
JMS
JDBC
Client
ORMI/HTTP
O
R
M
I
JTA
EJB
Container
JavaMail
JAF
EJB Client
OC4J Server Process
JSP Translator
•
Feature Rich and Very Fast JSP Translator
•
Full JSP 1.1 implementation
•
Supports all JSP Tag Directives
•
JSP Tag Libraries
•
– Supports all standard JSP Tags
– Very Fast JSP Translator
– Most Advanced JSP 1.1 Support
–
–
–
–
Tag Library Assembly Tool to describe/package tag libs
Utility Tags: DB Access, Mail, Search, Multimedia
EJB Client Access Tags
JSP Caching Tags
Source Level Debugging
– Extended exception reporting with JSP and servlet line numbers to
assist with debugging
Servlet Engine
• Feature Rich and Very Fast Servlet Engine
• Full Servlet 2.2 implementation
– Servlet 2.2 compatible with Tomcat
– Standard .WAR file-based Deployment
– Very Fast compared to JServ, Tomcat, BEA, IBM
• Most Advanced Servlet 2.3 support
– Servlet Filters
– Servlet Chaining
• Automatic Servlet Compilation Support
– Compile on demand model eases development effort
• Stateless and Stateful Failover (Clustering)
EJB Container
• Competitive EJB Container
• Complete EJB 1.1 implementation
–
–
–
–
–
–
Session Beans and Entity Beans, Full CMP and BMP
Automatic Generation of Finder Methods
Simple and Complex O-R Mappings
Automatic Mapping of Fields to DB Tables
EAR File Deployment
Standard Services: JNDI 1.2, JMS 1.0, JTA 1.0.1
• Hot Deployment
– Automatic generation of EJB stubs upon deployment
• Advanced EJB 2.0 Support
– Draft O-R Mapping
– XML Deployment Descriptors
– Message Driven Beans
OC4J Java Database Connectivity
• Fully implements JDBC 2.0 specification
• Provides Oracle JDBC drivers
– Type 2 and Type 4 drivers
– Certified with Oracle 8, 8i, 9i out of the box
• Implements JDBC 2.0 extensions
– Connection pooling, advanced data types (BLOB, CLOB,
Character Streams etc), enhanced result sets, JNDI data
sources, X/A support
• Certified with Merant Type 4 JDBC drivers
– Merant provides access to non-Oracle data sources such
as Informix, Sybase, DB2, SQL-Server
OC4J Other APIs and Services
• JNDI, provides lightweight JNDI implementation
• JTA, provides transactions support including container
managed transactions
• JMS, provides lightweight message service implementation
• RMI
– Provide high speed, optimized RMI transport protocol
– Tunnels RMI over HTTP for firewall support
• HTTP(S), provide high performance HTTP server
OC4J Clustering Services
•
A cluster can be thought of a collection of servers operating
together that provide:
– Load balancing
– High availability
– Fault tolerance
•
OC4J provides these clustering services
– Load balancing
– High availability
– Fault tolerance
OC4J Load Balancing
•
Load balancer routes incoming client requests over multiple
OC4J servers
– Load balancer treats OC4J servers as a pool to handle
incoming requests
– Optimizes requests by servicing clients with same server
OC4J High Availability
•
Failed server detection
– Load balancer detects failed servers
– Load balancer routes requests around failed servers
• Dynamic server binding
– Servers register with load balancer when they start
– Load balancer adds server to pool upon registration
OC4J Application Failover
• Ensures that client sees no loss of service when a
server failure occurs
– Client state made available to fail-over servers
• Cluster island
– Servers grouped together inside of cluster
• Replicated application state
– HttpSession objects; client specific state
Web Application Clustering
One application server cluster
• Five application server nodes
• Two cluster islands
• Load balancer
Load Balancer
Application Server Cluster
Cluster Island 1
Cluster Island 2
Web Application Clustering
• Each server registers with the
load balancer at startup
Load Balancer
Application Server Cluster
Cluster Island 1
Cluster Island 2
Web Application Clustering
• Client makes requests for a
web application
• Load balancer intercepts
request
Client
Load Balancer
Application Server Cluster
A
B
C
Cluster Island 1
Cluster Island 2
Web Application Clustering
• LB routes request to a server
for processing
• Server A creates session for
client
Client
•Server A generates and
sends response
Load Balancer
Application Server Cluster
A
B
C
Cluster Island 1
Cluster Island 2
Web Application Clustering
• Server A sends
HttpSession object to
other servers in cluster
island
Client
• State not sent to servers
in other cluster islands
Load Balancer
Application Server Cluster
A
B
C
Cluster Island 1
HttpSession
Cluster Island 2
Web Application Clustering
• Future requests from same
client directed to same server
node for efficiency
Client
• HttpSession object continues
to be updated on all nodes
within cluster island
Load Balancer
Application Server Cluster
A
B
C
Cluster Island 1
HttpSession
Cluster Island 2
Web Application Clustering
• Server A experiences a
Client
major failure and stops
functioning
Load Balancer
Application Server Cluster
A
B
C
X
Cluster Island 1
HttpSession
Cluster Island 2
Web Application Clustering
• Client makes next request
• LB detects failure of server A
• LB routes request to another
server in same island
Client
• Server B generates
response using replicated
HttpSession object and
sends to client
Load Balancer
Application Server Cluster
A
B
C
X
Cluster Island 1
HttpSession
Cluster Island 2
Web Application Clustering
• Client sees no interruption of
service due to the failure
of server A
Client
• Server B sends updated
HttpSession object
to servers in cluster
Load Balancer
Application Server Cluster
A
B
C
X
Cluster Island 1
HttpSession
Cluster Island 2
Improve Scalability
Cluster Instances with Load Balancing
Cluster 1
Load
Web Server
(9iAS)
Balance
Web Server
(9iAS)
Web Server
(9iAS)
Load
Web Server Load
(9iAS)
Balance
Balancer
Web Server
(9iAS)
J2EE
Container
State
J2EE
Container
State
J2EE
Container
State
J2EE
Container
State
DB
Cluster 2
J2EE
Container
State
J2EE
Container
State
J2EE
Container
State
J2EE
Container
State
Accelerate Performance with Caching
Web Cache
(pre-cached pages)
Oracle9iAS
IBM
Oracle
Database
Tables
Files
interMedia
Microsoft
LOB
XML
Web Cache serves web pages 3X faster
–
–
–
–
Support more users, use less web servers, hardware
Oracle9iAS serves static and dynamic web pages faster
Provides sophisticated invalidation mechanisms
Higher reliability with surge protection, load balancing &
performance assurance
9iAS WebCache Services
AS
Web Cache
(pre-cached pages)
AS
Any Data
AS
• Serve 80% of Hits from Web Cache
• Web Site Works Faster
• Fewer Web Servers Needed
AS
Oracle9i
Oracle9iAS
Oracle WebCaching
9iAS WebCache Services
Cache 2
UK Data Center
Cache 1
US
• Eliminates Need To Go Over
ISP Networks
• Site Works Faster
Cache 3
Japan
Oracle9i AS
9iAS WebCache Services
Comparative Throughput of Store Sites
Requests / Second
Web Cache Content
• Search results
• Catalogs
• Personalized pages
• Images
• Text
• Audio / Video
7500
50
Average Store
performance
per Web server
Store with Oracle’s
Web caching on
single 2-CPU
Pentium III server
Provide High Availability
Cluster Mid-Tiers and Provide Application Failover
Clustered 9iAS
(Session State)
Web Server Load
(9iAS)
Balance
Replicated
State
Replicated
State
Replicated
State
Replicated
State
Clustered Oracle DB
(Persistent State)
Node
A
Node
B
Node
C
J2EE
App.
JDBC
(TAF)
9iAS
Node
D
Oracle9i Developer Suite
JDeveloper9i
Designer
Forms Developer
Oracle Portal
Reports Developer
Discoverer Admin. Edition
One Toolset, Enabling Oracle9i
Integration with JDeveloper9i
• End-to-End Solution to problem “How do I build a J2EE
Application”
• Innovative IDE for Java & XML Developers
–
–
–
–
100% Java
Common IDE for Oracle
Full lifecycle development
Available NT/2000, Solaris, Linux (JDK 1.3)
• End-to-End Support for J2EE Development
– UML Modeling
– Productive J2EE Framework. Wizards, code editors and visual
design tools to develop J2EE specification, including applets,
applications, JavaBeans, JavaServer Pages, servlets &
Enterprise JavaBeans
– Source Control Management – also 3rd party
Integration with JDeveloper9i
•
•
•
•
Unique XML, Java & SQL Integration
Universal client support
Profiler, CodeCoach & Debugger
Integrated support for Oracle9iAS Containers for J2EE
(OC4J)
• Integrated UML Class and Activity Modelers
• Enhanced database integration features
• Java Addin API for customizing Jdeveloper
Integration with JDeveloper9i
• Easy J2EE Deployment
• Create J2EE Archives through Wizards
– Create EJB JAR file for Business Logic
– Create WAR file for JSP Pages and Servlets
– Create EAR file for complete J2EE App
• One-click Deployment to 9iAS
Why OC4J ?
•
No Vendor Lockin
–
–
–
•
Robust Enterprise Strength J2EE platform
–
–
•
Performance, Scalability and Security
High Availability through Clustering
Improves Developer Productivity
–
–
•
Comprehensive support for industry standards - J2EE
Supports standard Java development and profiling tools
Access to non-Oracle data sources
Integrated development tools
Complete support for all phases of development lifecycle
Better Return on Your Investment
Why OC4J ?
Reduces Development, Deployment, Management and ongoing
Support Costs
–
–
–
–
–
Integrated with other Oracle9iAS components
Common technology stack
Pre-certified configurations
Single Vendor for all your platform needs
Management simplicity
Integrated with the world’s best Database - Oracle9i
–
–
–
–
End-to-End Security
End-to-End Availability
End-to-End Scalability
Real Application Clusters
Summary
Oracle9iAS provides a comprehensive J2EE server
Oracle9iAS provides tightly integrated tools for developing Java
applications
Oracle9iAS provides the best performance of all J2EE servers
Oracle9iAS provides the best integration with middle-tier
infrastructure needed to build web applications
OC4J provides clustering services for 24x7 support – no extra
costs
Oracle9iAS provides the best integration with the Oracle9i Database
Download OC4J from
http://otn.oracle.com
http://otn.oracle.com/docs/tech/java/oc4j/htdocs/getstart.htm
http://otn.oracle.com/jdeveloper
Try it out for yourself !
Q&
A
Q U E S T I O N S
A N S W E R S