• Aucun résultat trouvé

[PDF] L’architecture J2EE support de cours de base | Cours j2ee

N/A
N/A
Protected

Academic year: 2021

Partager "[PDF] L’architecture J2EE support de cours de base | Cours j2ee"

Copied!
49
0
0

Texte intégral

(1)

Introduction to

(2)

Session Objectives

Understanding the value propositions of

J2EE

Getting a big picture of J2EE architecture and

platform

Getting high-level exposure of APIs and

Technologies that constitute J2EE

You don't have to understand all the details

Understanding why J2EE can be used for as

(3)
(4)

Challenges

Portability

Diverse

Environments

Time-to-market

Core Competence

Assembly

Integration

Key

Technologies

J2SE

J2EE

JMS

Servlet

JSP

Connector

XML

Data

Binding

Products

App Servers

Web Servers

Components

Databases

Object to DB

tools

Legacy

Systems

Databases

Enterprise Computing

(5)

What Is the J2EE?

Open and standard based platform for

developing, deploying and managing

n-tier, Web-enabled, server-centric, and

(6)

The Java™ Platform

High-End

Server

Java Technology

Enabled Desktop

Workgroup

Server

Java Technology

Enabled Devices

(7)

The Java

TM

Platform

Optional Packages

Java 2

Enterprise

Edition

(J2EE)

Java 2

Standard

Edition

(J2SE)

Java Optional Packages Personal Basis Profile Personal Profile

Foundation Profile

MIDP

Java 2 Platform Micro Edition

(J2ME

TM

)

(8)
(9)

Open and Standard Solution

Use "component and container" model in

which container provides system services in

a well-defined and as industry standard

J2EE is that standard that also provides

portability of code because it is based on

Java technology and standard-based Java

programming APIs

(10)
(11)

Platform Value to Developers

Can use any J2EE implementation for

development and deployment

Use production-quality standard implementation which is

free for development/deployment

Use high-end commercial J2EE products for scalability and

fault-tolerance

Vast amount of J2EE community resources

Many J2EE related books, articles, tutorials, quality code

(12)

Platform Value to Vendors

Vendors work together on specifications and

then compete in implementations

In the areas of Scalability, Performance,

Reliability, Availability, Management and

development tools, and so on

Freedom to innovate while maintaining the

portability of applications

Do not have create/maintain their own

(13)

Platform Value to Business Customers

Application portability

Many implementation choices are possible

based on various requirements

Price (free to high-end), scalability (single CPU to

clustered model), reliability, performance, tools,

and more

Best of breed of applications and platforms

(14)

J2EE APIs &

Technologies

(15)

J2EE 1.4 APIs and Technologies

J2SE 1.4 (improved)

JAX-RPC (new)

Web Service for J2EE

J2EE Management

J2EE Deployment

JMX 1.1

JMS 1.1

JTA 1.0

Servlet 2.4

JSP 2.0

EJB 2.1

JAXR

Connector 1.5

JACC

JAXP 1.2

JavaMail 1.3

JAF 1.0

(16)

Java EE 5

JAX-WS 2.0 & JSR 181

Java Persistence

EJB 3.0

JAXB 2.0

JavaSever Faces 1.2 – new to Platform

JSP 2.1 – Unification w/ JSF 1.2

(17)

Servlet &

JSP (JavaServer

Pages)

(18)

What is a Servlet?

Java™ objects which extend the functionality

of a HTTP server

Dynamic contents generation

Better alternative to CGI, NSAPI, ISAPI, etc.

Efficient

Platform and server independent

Session management

(19)

Servlet vs. CGI

CGI

Based

Webserver

CGI

Based

Webserver

Request CGI1

Child for CGI1

CGI

Based

Webserver

Servlet Based Webserver

Request CGI1

Child for CGI1

Request Servlet1

CGI

Based

Webserver

Servlet Based Webserver

Servlet1

Request CGI1

Child for CGI1

Request CGI2

Request Servlet1

CGI

Based

Webserver

Child for CGI2

Servlet Based Webserver

Servlet1

Request CGI1

Child for CGI1

Request CGI2

Request Servlet1

Request Servlet2

CGI

Based

Webserver

Child for CGI2

Servlet Based Webserver

Servlet1

Request CGI1

Child for CGI1

Request CGI2

Request CGI1

Request Servlet1

Request Servlet2

CGI

Based

Webserver

Child for CGI2

Child for CGI1

Servlet Based Webserver

Servlet1

Request CGI1

Child for CGI1

Request CGI2

Request CGI1

Request Servlet1

Request Servlet2

CGI

Based

Webserver

Child for CGI2

Child for CGI1

Servlet Based Webserver

JVM

Servlet1

Request CGI1

(20)

What is JSP Technology?

Enables

separation

of

business logic

from

presentation

Presentation is in the form of HTML or

XML/XSLT

Business logic is implemented as

Java Beans

or custom tags

Better maintainability, reusability

Extensible via custom tags

(21)

EJB

(Enterprise Java

Beans)

(22)

What is EJB Technology?

A

server-side component

technology

Easy development and deployment of Java

technology-based application that are:

Transactional, distributed, multi-tier, portable,

(23)

Why EJB Technology?

Leverages the benefits of

component-model

on the server side

Separates

business logic

from system code

Container provides system services

Provides framework for

portable components

Over different J2EE-compliant servers

Over different operational environments

Enables

deployment-time configuration

(24)
(25)

Enterprise JavaBeans

Enterprise JavaBeans

Entity Bean

Message-Driven Bean

Synchronous communication

Asynchronous communication

Stateless

Stateful

Bean managed

Container managed

(26)

JMS

(Java Message

Service)

(27)

Java Message Service (JMS)

Messaging systems (MOM) provide

De-coupled communication

Asynchronous communication

Plays a role of centralized post office

Benefits of Messaging systems

Flexible, Reliable, Scalable communication

systems

Point-to-Point, Publish and Subscribe

JMS defines standard Java APIs to

(28)

Connector

Architecture

(29)

Connector Architecture

Defines standard API for integrating J2EE

technology with EIS systems

CICS, SAP, PeopleSoft, etc.

Before Connector architecture, each App server has

to provide an proprietary adaptor for each EIS

system

m (# of App servers) x n (# of EIS's) Adaptors

With Connector architecture, same adaptor works

(30)

m x n Problem Before Connector

Architecture

App

Server1

App

App

Server3

App

Server2

SAP

EIS4

EIS3

m

n

EIS

2

(31)

JAAS (Part of J2SE

1.4)

(Java Authentication &

Authorization Service)

(32)

JAAS: Authentication

Pluggable authentication framework

Userid/password

Smartcard

Kerberos

Biometric

Application portability regardless of authentication

schemes underneath

JAAS provides authentication scheme independent API

Authentication schemes are specified Login configuration

(33)
(34)

Other J2EE APIs &

Technologies

(35)

JNDI

Java Naming and Directory Interface

Utilized by J2EE applications to locate

resources and objects in portable fashion

Applications use symbolic names to find object

references to resources via JNDI

The symbolic names and object references have

to be configured by system administrator when

the application is deployed.

(36)

JDBC

Provides standard Java programming

API to relational database

Uses SQL

Vendors provide JDBC compliant driver

which can be invoked via standard Java

programming API

(37)

J2EE Management (JSR-77)

Management applications should be able to

discover and interpret the managed data of

any J2EE platform

Single management platform can manage

multiple J2EE servers from different vendors

Management protocol specifications ensure a

uniform view by SNMP and WBEM

management stations

(38)

J2EE Deployment (JSR-88) - J2EE 1.4

Tools

J2EE Platforms

Standard

Deployment API

(Universal Remote)

IDEs

Vendor Deploy

Tools

(39)

J2EE App Server

App

JMX

JMX

JMX defacto

Dynamic Deployment

JMX API into

the J2EE 1.4 platform

(40)

J2EE is an End-to-End

Architecture

(41)
(42)

J2EE

Component & Container

Architecture

(43)

J ND I J2SE J MS RM I/IIOP J DB C App Client

App Client Container

HTTP/ HTTPS J2SE RMI J2SE J ND I J MS RM I/IIOP J DB C J T A JavaMail JAF JNDI JMS RM I/IIOP J DB C J T A JavaMail JAF HTTP/ HTTPS Applet Container

Applet JSP Servlet EJB

Web Container EJB Container

RMI

J2SE

(44)

Components

Handle

Concurrency

Security

Availability

Scalability

Persistence

Transaction

Life-cycle

management

Presentation

Business Logic

Containers

Handle

(45)

Containers & Components

Containers do their work invisibly

No complicated APIs

They control by interposition

Containers implement J2EE

Look the same to components

Vendors making the containers have great

freedom to innovate

(46)

J2EE Application

Anatomies

(47)

DB & EIS

Resources

Browser

Stand-alone

Web Server

EJB Server

Web Server

EJB Server

Possible J2EE Application

Anatomies

(48)

J2EE Application Anatomies

4-tier J2EE applications

HTML client, JSP/Servlets, EJB, JDBC/Connector

3-tier J2EE applications

HTML client, JSP/Servlets, JDBC

3-tier J2EE applications

EJB standalone applications, EJB, JDBC/Connector

B2B Enterprise applications

(49)

Which One to Use?

Depends on several factors

Requirements of applications

Availability of EJB tier

Références

Documents relatifs

APPROVES the regional (inter-country) projects proposed to be financed by Technical Assistance funds, and requests that these projects be approved by the

Cet appel a pour objectif d’identifier un prestataire de services qui s’occupera de la production d’un rapport d’analyse des commentaires enregistrés sur les réseaux sociaux

Les offrants doivent convenir que le prix à facturer pour tous les matériaux en bois utilisés dans la production des articles sera au prix coûtant qui ne peut inclure que le

Note: Please note that the Ministère de l’Enseignement supérieur always sends documents to the mailing address of the person making the request. Incomplete requests will not

The Code of Conduct applies to individuals doing business on behalf of the Canadian Alliance of Physiotherapy Regulators (CAPR) including members of the Board of Directors

Section 2.6 is devoted to the discussion of the relation of the hypothesis introduced and the Peierls condition (the Gertsik-Pirogov-Sinai condition). 2.7 we illustrate

This agreement is intended to constitute the basis on which Channel Regulatory Authorities will request an amendment to the common methodology for coordinated redispatch

 Veuillez indiquer la couleur pantone pour les boutons para 3.8.1.2, Coyote Brown.. À partir de la photo de la modification 001 fournie et de l'expédition précédente que nous