Description: This hands-on course provides participants with the knowledge and experience required to develop and deploy robust Java EE (Java Enterprise Edition) web applications. The focus of the course is on building web-enabled applications that employ Servlets, JavaServer Pages and Tag Libraries to exploit the services provided by the Java EE platform. This course covers architectural design issues as well as specific coding models for Java EE components, and is up to date with the latest Java EE 5, JSP 2.1 and Servlet 2.5 specifications. Security, transaction management, inter-component communication and deployment issues are discussed in detail, with hands-on labs to solidify understanding. Since coding and deployment files are standardized by the Jave EE specifications, students may readily apply the skills learned in this class to write code for any compliant server, including Apache Tomcat, JBoss, WebSphere, Oracle, WebLogic and many others. Students will understand the role and architecture of the most important containers in the Java EE specification: the Web Container (which hosts HTML pages, Servlets and JSP Pages) and the EJB Container (which hosts Enterprise JavaBean components). Participants will learn how to use important Java EE services and protocols including JNDI, JDBC and JMS. Students will learn how to utilize ANT, a flexible and powerful XML-based build utility, to compile, deploy and execute stand-alone and enterprise Java applications. Comprehensive hands-on lab exercises reinforce instructor lectures and build direct competence in the topics presented throughout the course.
Prerequisites: Java SE 5 programming experience and an understanding of object-oriented design principles. Fundamental knowledge of XML and HTML is helpful but not required.
Overview of Topics Covered:
Introduction to Java EE Web Applications
Server-Side Application Development using Java EE
The Role of Java EE Containers, Components and Services
Using Web-Based Components in Application Design
Structure of Java EE Web Components
Deploying Web Applications
Java EE Web Container Services
Using ANT
Understanding the ANT Build File
Designing ANT Targets
Using ANT Standard Tasks
Using ANT Properties
Compiling and Executing Java Applications
Building WAR, EAR and JAR Deployment Files
Introduction to Servlets
Servlet Architecture and Advantages
The Role of Servlets in Web Application Design
Servlet Runtime Environment
Servlet Lifecycle
Developing Servlets
Servlet Classes and Interfaces
Working with Request and Response Objects
Processing GET and POST Requests from Web Clients
Retrieving Parameters from HTML Client Forms
Generating Dynamic HTML Responses
Initializing Servlets
Destroying and Freeing Resources in Servlets
Controlling Single and Multi-Threading in a Servlet
Deploying Servlets to a Web Application Server
Building the WAR file
The web.xml descriptor file
Developing JavaServer Pages (JSPs)
Understanding JSP/Servlet Translation
Elements of JSP Syntax
JSP Page Directives
JSP Declarations
Displaying JSP Expressions
Writing Scriptlets
Deploying JSPs
Using JavaBeans in JSPs
JavaBean Architecture
Creating JavaBeans
Using JavaBeans in JSP Pages
XML-format JSP Documents
Deploying and Using Tag Libraries
Motivation for Tag Libraries
Implementing the Model-View-Controller Pattern
JSP built-in Actions
The JSP Standard Tag Library (JSTL)
Deploying and using Tag Libraries
Writing Tag Handlers
Analyzing Tag Library Descriptor Files
Creating Tag Library Descriptor Tags
Using Tag Handler Methods to
Generate Dynamic Web Content
Handling Tag Attributes and Attribute Validation
Processing Tag Body Content
Working with the TagExtraInfo Class
Developing and Deploying Tag Files
Session Management and Communication Between Web Components
Storing Shared, Scoped Information
Java EE Session Management
Maintaining Sessions via URL Rewriting
Using Cookies
Using Hidden Form Fields to Track Session IDs
Using the HttpSession Interface
Transferring Control via Request Dispatching
Request Redirection
Developing Secure Web Applications
Understanding JAAS Concepts
Java EE Authentication and Authorization
Defining Security Roles
Declaring Security Constraints
Using Programmatic Security
Using Java SE Security Features
Encryption, Message Digests and Keys
Java Naming and Directory Interface (JNDI)
Role of JNDI in the Java EE Architecture
JNDI Service Providers
Importing and Utilizing JNDI Packages
Binding Objects with JNDI
Looking up Objects with JNDI
Using the Environment Naming Context (ENC)
Declaring Resource References
Object Serialization
Purpose of Serialization in the Java EE Framework
Creating Serializable Objects
Reading and Writing SerializableObjects
Controlling Serialization
Advanced Topics - Filters, Listeners and Resource Injection
Using Filters to process Requests and Responses
Controlling the Filter Chain
Writing Filters
Wrapping Requests and Responses
Writing and Deploying Listeners
Using Annotations in Servlet 2.5 Applications
Controlling Resource Injection
Using Special Resource Types
Accessing Databases with JDBC
Understanding the JDBC Connectivity Model
Accessing Data Sources through JNDI
Connecting to a Database
Executing SQL Queries and Updates
Processing Result Sets
Using Scrollable and Sensitive Result Sets
Working with ResultSetMetaData Classes
Utilizing Parameterized Statements
Calling Stored Procedures
Handling SQLExceptions
Controlling Transactions
Using Batch Updates
Using the Java Messaging Service (JMS)
Architecture of JMS
Using Classes and Interfaces in the JMS API
Developing a JMS Producer and Consumer
Introduction to Enterprise JavaBeans
How EJBs are Used
Bean Developer, Bean Deployer and Application Assembler Roles
Session, Entity and Message Driven Beans
EJB Container Services
Deploying Enterprise Java Beans
Creating the EJB Deployment Descriptor
Accessing Enterprise Java Beans
Java and all Java-based marks are trademarks or registered trademarks of Sun Microsystems, Inc. in the U.S. and other countries.