Contents
Chapter 1: An introduction to EJB development
Why we need Enterprise JavaBeans
Roles in the development of an EJB application
Application roles
Infrastructure roles
Deployment and operation roles
EJB architecture
The EJB server
The EJB container
How an enterprise bean works
Types of enterprise beans
Chapter 2: Developing enterprise beans with JBuilder
Setting up the target application server
Making the ORB available to JBuilder
Selecting an application server
Creating an EJB group
Creating an enterprise bean
Adding the business logic to your bean
Exposing business methods through the remote interface
Creating the home and remote interfaces for an existing bean
Compiling the bean
Editing deployment descriptors
Differences in how JBuilder 3.5 and 4 store deployment descriptors
Creating entity enterprise beans with the EJB Entity Bean Modeler
Creating a test client application
Using the test client application
Testing your enterprise bean
Chapter 3: Deploying enterprise beans
Creating a deployment descriptor file
The role of the deployment descriptor
The types of information in the deployment descriptor
Deploying to an application server
Deploying a single JAR file
Deploying multiple JAR files
Chapter 4: Using the Deployment Descriptor editor
Displaying the Deployment Descriptor editor
Viewing the deployment descriptor of an enterprise bean
Adding information for a new enterprise bean
Changing bean information
Enterprise bean information
Main panel
Environment panel
EJB references panel
Security role references panel
Resource references panel
Persistence panel
Finders panel
Properties panel
Container transactions
Adding a container transaction
Working with data sources
Setting isolation levels
Setting data source properties
Adding security roles and method permissions
Creating a security role
Assigning method permissions
Verifying descriptor information
Chapter 5: Developing session beans
Types of session beans
Stateful session beans
Stateless session bean
Writing the session bean class
Extending the SessionBean interface
Writing the business methods
Adding one or more ejbCreate()
methods
How JBuilder can help you create a session bean
The life of a session bean
Stateless beans
Stateful beans
A shopping cart session bean
Examining the files of the cart example
The CartBean session bean
Item class
Exceptions
Required interfaces
Chapter 6: Developing entity beans
Persistence and entity beans
Bean-managed persistence
Container-managed persistence
Primary keys in entity beans
Writing the entity bean class
Extending the EntityBean interface
Declaring and implementing the entity bean methods
Using JBuilder wizards to create an entity bean
The life of an entity bean
The nonexistent state
The pooled state
The ready state
Returning to the pooled state
A bank entity bean example
The entity bean home interface
The entity bean remote interface
An entity bean with container-managed persistence
An entity bean with bean-managed persistence
The primary key class
The deployment descriptor
Chapter 7: Creating the home and remote interfaces
Creating the home interface
The EJBHome base class
Creating a home interface for a session bean
Creating a home interface for an entity bean
Creating the remote interface
The EJBObject
Chapter 8: Developing enterprise bean clients
Locating the home interface
Getting the remote interface
Session beans
Entity beans
Calling methods
Removing bean instances
Referencing a bean with its handle
Managing transactions
Discovering bean information
Creating a client with JBuilder
Chapter 9: Managing transactions
Characteristics of transactions
Transaction support in the container
Enterprise beans and transactions
Bean- versus container-managed transactions
Transaction attributes
Local and global transactions
Using the transaction API
Handling transaction exceptions
System-level exceptions
Application-level exceptions
Handling application exceptions
© 1997, 2000 by INPRISE Corporation, Inc.
All Rights Reserved