8
(703)246-9100 Northern Virginia (804)285-5830 Central Virginia (757)420-3810 Tid (800)294-7497 Toll Free (804)285-3722 Fax www.ACTisIT.com Developing J2EE Applications using Hibernate and RAD Duration: 5 days This training course provides students with the knowledge needed to develop J2EE applications using Hibernate, this Object/Relational Mapping (ORM) framework is used to implement the persistence layer of J2EE applications. The IDE for this class is RAD (Rational Application Developer) from IBM. Topics Developing J2EE Applications. Servlets. JSP’s. MVC Development hierarchy. Hibernate JDBC Development. Object/Relational Mapping (ORM) Concepts. Hibernate Architecture and Configuration. Basic Hibernate Mappings. Manipulating Persistent Objects. Advanced Hibernate Mappings. Hibernate Transactions and Concurrency. Performance with Hibernate. Hibernate Tools. Hibernate different Design Techniques. Practical work This course covers extensive practical exercises; these exercises take students through all major aspects of the design and development of J2EE applications and it major components. The course will mainly focus on J2EE applications using Hibernate. After completing this course, the student should be able to: Understand how to develop J2EE applications. Understand how to develop efficient JSP’s and Servlets. Use RAD to Develop J2EE applications. Understand the concepts of Object/Relational Mappings. Understand the architecture of Hibernate. Integrate and configure Hibernate in J2EE applications. Create Hibernate mappings. Retrieve and update persistent objects using Hibernate. Use HQL (Hibernate Query Language) and criteria queries. Know when to use database and application transactions. Understand the Hibernate caching architecture. Tune performance of Hibernate operations. Use various Hibernate tools. Audience Software designers, developers and programmers Prerequisites Understand how to program in Java

Developing J2EE Applications Using Hibernate and RAD J2EE Applications Using Hibernate... · Developing J2EE Applications using Hibernate and RAD ... • Servlets. • JSP’s

Embed Size (px)

Citation preview

(703)246-9100 Northern Virginia(804)285-5830 Central Virginia

(757)420-3810 Tidewater Area(800)294-7497 Toll Free

(804)285-3722 Faxwww.ACTisIT.com

Developing J2EE Applications using Hibernate and RAD Duration: 5 days This training course provides students with the knowledge needed to develop J2EE applications using Hibernate, this Object/Relational Mapping (ORM) framework is used to implement the persistence layer of J2EE applications. The IDE for this class is RAD (Rational Application Developer) from IBM. Topics

• Developing J2EE Applications. • Servlets. • JSP’s. • MVC Development hierarchy. • Hibernate JDBC Development. • Object/Relational Mapping (ORM) Concepts. • Hibernate Architecture and Configuration. • Basic Hibernate Mappings. • Manipulating Persistent Objects. • Advanced Hibernate Mappings. • Hibernate Transactions and Concurrency. • Performance with Hibernate. • Hibernate Tools. • Hibernate different Design Techniques.

Practical work This course covers extensive practical exercises; these exercises take students through all major aspects of the design and development of J2EE applications and it major components. The course will mainly focus on J2EE applications using Hibernate. After completing this course, the student should be able to:

• Understand how to develop J2EE applications. • Understand how to develop efficient JSP’s and Servlets. • Use RAD to Develop J2EE applications. • Understand the concepts of Object/Relational Mappings. • Understand the architecture of Hibernate. • Integrate and configure Hibernate in J2EE applications. • Create Hibernate mappings. • Retrieve and update persistent objects using Hibernate. • Use HQL (Hibernate Query Language) and criteria queries. • Know when to use database and application transactions. • Understand the Hibernate caching architecture. • Tune performance of Hibernate operations. • Use various Hibernate tools.

Audience Software designers, developers and programmers Prerequisites Understand how to program in Java

(703)246-9100 Northern Virginia(804)285-5830 Central Virginia

(757)420-3810 Tidewater Area(800)294-7497 Toll Free

(804)285-3722 Faxwww.ACTisIT.com

Developing J2EE Applications using Hibernate and RAD Duration: 5 days Course Content 1. J2EE Overview

• Introduction • Why Do We Need J2EE? • J2EE Components • J2EE Technologies • Useful J2SE Technologies • Application Artifacts • J2EE Architecture • J2EE 1.4 Version Levels • J2EE Software Packaging • Deployment Descriptor • Enterprise Archive (EAR) • Web Modules and WAR • EJB Modules • Building Module Dependency • Objectives • Project Explorer • Servers View • The J2EE Perspective • The Web Perspective • RAD Project Structure • Create an Enterprise Application • Setup Utility JAR • Create an EJB Project • Create a Web Project • Setup Dependent JAR Files • Create Server Instance and Server Configuration • Configure Server Instance • Add an Enterprise Application Project to the Test Server • Start and Stop the Server • Test a Servlet • Debug a Servlet • Test a JSP • Debug a JSP • Automatic Code Reloading

2. Using the IDE • Project Explorer • Servers View • The J2EE Perspective • The Web Perspective • RAD Project Structure • Create an Enterprise Application • Setup Utility JAR • Create an EJB Project • Create a Web Project • Setup Dependent JAR Files • Create Server Instance and Server Configuration • Configure Server Instance • Add an Enterprise Application Project to the Test Server

(703)246-9100 Northern Virginia(804)285-5830 Central Virginia

(757)420-3810 Tidewater Area(800)294-7497 Toll Free

(804)285-3722 Faxwww.ACTisIT.com

Developing J2EE Applications using Hibernate and RAD Duration: 5 days

• Start and Stop the Server • Test a Servlet • Debug a servlet • Test a JSP • Debug a JSP • Automatic Code Reloading

3. Developing Servlets • Objectives • History CGI • Server Extension APIs • Java Servlet • Servlet Container • Servlet Responsibilities • J2EE and Servlet • The Servlet Class • The HttpServlet Class • An Example Hello World • The Servlet Container • The Servlet API • Life Cycle Initialization • Life Cycle Initialization • Example Initialization • Life Cycle Processing • Life Cycle Processing • Life Cycle Destroy • User Input • Example User Input • Output to Client • Servlet Error Handling • Threading Issues • Create a Servlet in RAD • Code Servlet Methods • The Web Deployment Descriptor • Test the Servlet • Debug Servlets in the WebSphere Test Environment

4. Advanced Servlets • Objectives • Key Issues for Web Application Development Productivity • Web Application Programming Model MVC • Model • View • Controller • What is JDBC? • JDBC Architecture • JDBC: Basic Steps • Loading a Driver • DB2 UDB JDBC Drivers • Oracle JDBC Drivers • Create a Connection

(703)246-9100 Northern Virginia(804)285-5830 Central Virginia

(757)420-3810 Tidewater Area(800)294-7497 Toll Free

(804)285-3722 Faxwww.ACTisIT.com

Developing J2EE Applications using Hibernate and RAD Duration: 5 days

• Connection • Statement • PreparedStatement

5. J2EE and Advanced JDBC • Example JDBC Servlet With Transactions • Close the Connection • Need for Connection Pooling • Connection Pooling in JDBC 2.0 • Connection Pooling • Basic Steps in Using JDBC Connection Pooling • Access a DataSource • Get a Connection • Release Connections • Connection Pool Example • Resource References • JavaBeans • MVC Implementation • Request Dispatching • Request Dispatching - Forward vs. Include • HTTP Redirection • Dispatch vs. redirection • Integrating Servlet and JSP • Calling a JSP from a Servlet • Request Dispatching - forward Request to JSP • Supply Result information to the JSP • A Simple Example • Display JavaBean Properties in JSP • Creating a Data Source with RAD • Adding Resource Reference in RAD • Create a Java Bean with RAD • Add Attributes and Getters and Setters with RAD

6. Developing JSP’s • Objectives • JavaServer Pages • A Simple Example - Hello.jsp • JSP Benefits • Evolution of Dynamic Content Technologies • How JSP Works • JSP Invocation • JSP Scripting Elements • The XML Syntax • JSP Directive • page Directive Attributes • page Directive an Example • page Attribute errorPage • page Attribute isErrorPage • Using XML Syntax • Directives include • Include an Example

(703)246-9100 Northern Virginia(804)285-5830 Central Virginia

(757)420-3810 Tidewater Area(800)294-7497 Toll Free

(804)285-3722 Faxwww.ACTisIT.com

Developing J2EE Applications using Hibernate and RAD Duration: 5 days

• Include an Example • Include at compile time vs. at request time • Request time inclusion • JSP Declarations • Declarations an Example • JSP Expressions • JSP Expressions an Example • JSP Scriptlets • JSP Scriptlets an Example • JSP Comments • JSP Predefined Variables • The request Object • The response Object • The out Object • Out an Example • Creating a JSP with RAD • Editing a JSP with RAD • Testing a JSP with WSAD • Debugging a JSP with RAD

7. Introduction to Hibernate • Topics • What is Hibernate? • RDB Technology • Accessibility of Relational Databases from Java • The Structure of a Domain Model • The difference between Object and Relational Models • The concept of Identity Modeling • Granularity of Objects and Tables • Association Modeling • Navigation • Inheritance • What is Object/Relational Mapping? • Advantages of using an ORM Tool • Architecture of Hibernate • The Hibernate API • Extension Interfaces • Configuring Hibernate. • Hibernate Mappings • Mapping Hibernate • Using Hibernate XML Configuration Files • Non-Managed and Managed Environments • Configuration in a Non-Managed Environment • Configuration in a Managed Environment • Binding SessionFactory to JNDI • Other Alternatives to Hibernate • Comparison to EJB Entity Beans • Regular Hand-Coded Persistence Using JDBC • OOD, Object-Oriented Databases concept • Other ORM Tools

(703)246-9100 Northern Virginia(804)285-5830 Central Virginia

(757)420-3810 Tidewater Area(800)294-7497 Toll Free

(804)285-3722 Faxwww.ACTisIT.com

Developing J2EE Applications using Hibernate and RAD Duration: 5 days 8. Basic Mappings

• Creating the Domain Model • Hibernate Domain Model • Hibernate Domain Objects • Hibernate Requirements • Object Identity • Primary Keys • Natural Keys vs. Surrogate Keys • Identifier Property • Identifier Generators • Hibernate Managed Identifiers • Mapping Metadata • Mapping Properties • Property Access Strategies • Derived Properties • Preventing Insert/Update • Using Database Schemas • Quoted SQL Identifiers • Specifying Java Packages • Entity and Value Types • Components • Bi-Directional Components • Other Component Details • Association Mappings • Many-to-One Association • One-to-Many Association • Inheritance Mapping Strategies • Table per Concrete Class • Table per Subclass • Table per Class Hierarchy

9. Manipulating Persistent Objects • Different States of an Object • A Transient Objects • A Persistent Objects • A Detached Objects • Object Identity • Persisting a Transient Object • Retrieving and Updating a Persistent Object • Deleting a Persistent Object • Updating a Detached Object • Transitive Persistence • Using save-update • Differentiating Between Transient and Detached Objects • HQL Queries • Parameter Binding • Pagination • Named Queries • HQL Polymorphic Queries • HQL Restriction • HQL String Comparison

(703)246-9100 Northern Virginia(804)285-5830 Central Virginia

(757)420-3810 Tidewater Area(800)294-7497 Toll Free

(804)285-3722 Faxwww.ACTisIT.com

Developing J2EE Applications using Hibernate and RAD Duration: 5 days

• HQL Logical Operators • Ordering the Results • Join Queries • Implicit Joins • Where Clause Joins • Criteria Queries • Polymorphic Criteria Queries • Restricting Criteria Queries • Comparing Strings in Criteria Queries • Using Logical Operators in Criteria Queries • Ordering Results in Criteria Queries • Using Joins in Criteria Queries • Using Dot Notation to Get Component Properties

10. Advanced Mappings • One-to-One Associations • Many-to-Many Associations • Polymorphic Associations • Entity vs. Value Types • Built-in Mapping Types • Using Mapping Types • Custom Mapping Types • Collections of Value Types • Set of Value Types • Bag of Value Types • List of Value Types • Map of Value Types • Collections of Components • Sorting Collections

11. Transactions, Concurrency and Performance • Database Transactions • JDBC and JTA Transactions • Hibernate Transactions • Flushing the Hibernate Session • Isolation Issues • Isolation Levels • Configuring the Isolation Level • Pessimistic Locking • Application Transactions • Application Transaction Isolation • Managed Versioning • Using Existing Properties to Implement Optimistic Locking • Caching • Hibernate Cache Architecture • The First-Level Cache • The Second-Level Cache • Cache Concurrency Strategies • Enabling the Second-Level Cache • Cache Regions • Specifying a Cache Provider

(703)246-9100 Northern Virginia(804)285-5830 Central Virginia

(757)420-3810 Tidewater Area(800)294-7497 Toll Free

(804)285-3722 Faxwww.ACTisIT.com

Developing J2EE Applications using Hibernate and RAD Duration: 5 days

• Support for Cache Providers • Explicitly Evicting Objects From the Second-Level Cache • Fetching Strategies • Fetching Strategies in Mappings – Single Point Associations • Fetching Strategies in Mappings –Collections • Fetching Strategies in Mappings –Batches • Explicit Initialization of Lazily Loaded Objects • Fetching Strategies in HQL Queries • Fetching Strategies in Criteria Queries • The N+1 Selects Issue • Report Queries - Projections • Report Queries – Projections • Report Queries – Aggregation • Report Queries – Grouping

12. Tools and Design Techniques • Topics • Generating the Database Schema • Generating the Domain Model • Generating the Database Schema • Using Middlegen • Using XDoclet • The Open Session in View Pattern • Using a Natural Key • Using a Composite Key • Dealing with Database Triggers