At a glance
Java Data Objects are a standard mechanism for object persistence that can be used across all editions of the Java 2 platform. They provide a transparent persistence mechanism that enables an object model to be mapped to any type of data store, be it a relational database, an object oriented database or a file based system. JDO enables a fully object oriented domain model to be made persistent without changing any Java code. Only the client code needs to be JDO-aware, in order to connect to the data store and manage transaction boundaries. Using the J2EE Connector architecture, JDO can also be used as a persistence mechanism within an application server, taking advantage of declarative security and transactions.
Intended For
Java developers who want to use a standard persistence mechanism that is much more flexible and transparent than either JDBC or entity enterprise Java Beans. It is particularly relevant for developers who work with object-relational mapping, object oriented databases or those who manage data on portable devices. It is of particular interest for developers who build systems that span different editions of the Java 2 platform (i.e. enterprise, standard and/or micro) or who wish to migrate systems that currently use JDBC or proprietary object relational mapping tools. Also, web designers, web developers and other semi-technical webworkers who are interested in the visual front-end of websites. DHTML has application in intranets as well as the internet. Project managers may benefit too, as the subject matter is not highly technical but does reveal an enormous range of possibilities.
Prerequisites
The participant should have a working knowledge of Java and have some familiarity with the general issues of object persistence. Some knowledge of relational databases and Java application servers would be an advantage but is not essential.
Learning outcomes
At the end of the course, participants should have the following key skills:
- Be aware of the main problems in object persistence and how JDO addresses them
- Be able to persist an object model using a JDO implementation
- Understand how to write JDO client code to correctly handle persistence managers and transactions
- Understand the lifecycle of JDO objects
- Be able to deploy a JDO connector into an application server
Content
Module 1: Exploring Object Persistence
In this module we explore a number of issues in object persistence and the services that an object persistence framework should offer. We look at how objects are mapped to different types of data store and discuss different approaches to persistence.
Module 2: Java Persistence Technologies and JDO
Persistence in Java is a complex topic. In this module we look at a range of persistence technologies and explore how JDO compares to previous approaches and how it addresses many of the problems of object persistence.
Module 3: Developing Java Data Objects
In this introduction to JDO, we begin with an architectural overview of JDO development and see how an object model can be converted to Java Data Objects using an implementation of the JDO specification. We investigate testing, configuration, persistence descriptor metadata and the mapping process. We also introduce Solarmetric KoDo JDO.
Module 4: Using Java Data Objects
This module focuses on the JDO Client API, including the use of the PersistenceManager, JDO client workflow, JDO transactions and the JDO lifecycle.
Module 5: JDO Object Modeling
JDO provides full support for object oriented modeling. In this module we look at a number of aspects of a persistent object model, and look at how objects can be made persistent through capability, reachability or awareness. The management of object associations is also investigated.
Module 6: JDOQL, the JDO Query Language
The section covers JDOQL queries, how to create them, and how to navigate associations in queries. We also look at some query functions.
Module 7: Managing Object Identity
Object Identity in JDO can be datastore identity, application identity or non-durable identity. In this section we look at what we mean by object identity and compare the three options for object identity within JDO.
Module 8: Exceptions and Transactions
This module covers the handling of exceptions in JDO and some key features of transaction management, including optimistic versus pessimistic transactions and transaction isolation.
Module 9: Object-Relational Mapping
Mapping objects to relational databases is a key feature of object persistence technologies. This module discusses the main issues in object-relational mapping, describes types of O/R mapping and looks at O/R mapping features within JDO.
Module 10: Architecture and Design Patterns
In this architecture section we ask how JDO fits into an enterprise architecture and look at some architectural and design patterns for JDO.
Module 11: Enterprise JDO & J2EE
This module looks at how JDO can be used in enterprise Java applications, using web applications and/or Enterprise Java Beans. It describes how to deploying JDO in an application server using the J2EE Connector Architecture (J2EE CA).
Method Used
Each participant works at a PC and spends 60% of the time in practical exercises. The exercises work through a developing case study that demonstrates all the key features of JDO. The JDO implementation used for the exercises is KoDo JDO, the market leading JDO product.


