Java 2 – Enterprise Edition Kevin J. LaFata April 21, 2003 UM – St. Louis
Dec 20, 2015
Java 2 – Enterprise Edition
Kevin J. LaFata
April 21, 2003
UM – St. Louis
Overview
J2EE Intro Key Concepts JSP and Servlets XML Building and Deployment EJB More info and job market
What makes up J2EE
Enterprise Java Beans (EJB)
JDBC Java Messaging
Service Servlets JSP
JNDI Java Mail XML SOAP JAAS JTA and others…
J2EE as a Specification
Specifications Interfaces Libraries Implementations
Key Concepts
XML Deployment When & what to use OO Design Syntax – less important
JSP
JSP Directives HTML Embedded Code Tag Libraries/Custom Tags Sessions
JSP Translation
JSP Translated into a servlet Uses HTTPServlet package Servlet compiled and executed Done by Tomcat
Servlets
Special interface Uses response and request objects Run by a server such as Tomcat
JSP Example
Servlet Example
XML Importance
Used everywhere in Java Data standardization Configuration Files Deployment File
XML Basics
Special Header Like HTML Must be well formed All tags must be closed Tags can have data, attributes, other
tags DTDs
XML Example
XSLT
Translates XML to something Usually HTML Selection language Looping, conditionals
ANT
Like a Makefile Many Java specifics Defined using XML Build targets and tasks
ANT Example
Deployment
Jar files – Libraries War files – Web applications Ear files – EJB Deployments Manifests and information along with
class files and resources XML used to define deployment
descriptors
Enterprise Java Beans
Specifications Containers Adds scalability, thread safety,
transactions Security
Bean Types
Stateless Session Beans Stateful Session Beans Entity Beans
Session Beans
Perform actions Business rules and logic Can maintain session Pooled by server
Entity Beans
Represent data or objects Usually persistent Underlying data storage Storage can be handled by bean or by
server
Transactions
Atomic – all or nothing Consistency – data is valid Isolation – data locking Durability – data stays permanent
Implementations
JBoss BEA Weblogic IBM WebSphere Oracle Application Server Jakarta Tomcat
Learn by trying
Tomcat JBoss MySQL Oracle (Development)
For more information
100’s of books java.sun.com
Job Market
A.G. Edwards Anheuser Busch Enterprise Rent-A-Car
OO Design Important Side Projects Additional Skills