InfoCenter Home >
6: Administer applications >
6.6: Tools and resources quick reference >
6.6.5: Administering EJB modules (overview) >
6.6.5.0: EJB module properties >
6.6.5.0.1: Assembly properties for entity beans
6.6.5.0.1: Assembly properties for entity beans
- EJB name (Required, String)
- Specifies a logical name for the enterprise bean. This name must be
unique within the EJB module. There is no relationship between this
name and the JNDI name.
- Display name
- Specifies a short name that is intended to be displayed by GUIs.
- Description
- Contains text describing the entity bean.
- Home Interface (Required, String)
- Specifies the full name of the enterprise bean's home interface
class--for example,
com.ibm.ejs.doc.account.AccountHome.
- Remote Interface (Required, String)
- Specifies the full name of the enterprise bean's remote interface
class--for example,
com.ibm.ejs.doc.account.Account.
- EJB class (Required, String)
- Specifies the full name of the enterprise bean class--for example,
com.ibm.ejs.doc.account.AccountBean.
- Persistency
- Specifies whether an entity bean manages its own persistent storage or
whether storage is managed by the container. The valid values are
Bean-managed and Container-managed.
- Primary key field
- Specifies the name of a simple primary key. Simple primary keys map
to a single field in the entity bean class and are made up of primitive Java
data types (such as integer or long). If exactly one CMP field is the
primary key, it can be specified here.
- Primary key class (Required, String)
- Specifies the full name of the bean's primary key class--for
example,
com.ibm.ejs.doc.account.AccountKey.
Composite primary keys map to multiple fields in the entity bean class (or to
data structures built from the primitive Java data types), and must be
encapsulated in a primary key class. More complicated enterprise beans
are likely to have composite primary keys, with multiple instance variables
representing the primary key. A subset of the container-managed fields
is used to define the primary key class associated with each instance of an
enterprise bean.
- Reentrant
- Specifies whether the entity bean is reentrant or not. If an
enterprise bean is reentrant, it can invoke methods on itself or call another
bean that invokes a method on the calling bean. Only entity beans can
be reentrant. If an entity bean is not reentrant and a bean instance is
executing a client request in a transaction context and another client using
the same transaction context makes a request on the same bean instance, the
EJB container throws the java.rmi.RemoteException exception to
the second client. If a bean is reentrant, the container cannot
distinguish this type of illegal loopback call from a legal concurrent call
and the bean must be coded to detect illegal loopback calls.
- Small icon
- Specifies a JPEG or GIF file containing a small image (16x16
pixels). The image is used as an icon to represent the entity bean in a
GUI.
- Large icon
- Specifies a JPEG or GIF file containing a large image (32x32
pixels). The image is used as an icon to represent the entity bean in a
GUI.
- Inheritance root
- Specifies whether or not the enterprise bean is at the root of an
inheritance hierarchy.
- Bean Cache -- Activate at
- Specifies the point at which an enterprise bean is activated and placed in
the cache. Removal from the cache and passivation is also governed by
this setting. Valid values are Once and Transaction. Once
indicates that the bean is activated when it is first accessed in the server
process, and passivated (and removed from the cache) at the discretion of the
container--for example, when the cache becomes full. Transaction
indicates that the bean is activated at the start of a transaction and
passivated (and removed from the cache) at the end of the transaction.
The default value is Transaction.
- Bean Cache -- Load at
- Specifies when the bean loads its state from the database. The
value of this property implies whether the container has exclusive or shared
access to the database. Valid values are Activation and
Transaction. Activation indicates that the bean is loaded when it is
activated (Once or Transaction) and implies that the container has exclusive
access to the database. Transaction indicates that the bean is loaded
at the start of a transaction and implies that the container has shared access
to the database. The default is Transaction.
The settings of the Activate at and Load at properties govern which commit
options are used. The commit options are described in detail in the
Enterprise JavaBeans specification, version 1.1.
- For Commit Option A (implies exclusive DB access), use Activate at = Once
and Load at = Activation. This option reduces database I/O (avoids
calls to the ejbLoad function) but serializes all transactions accessing the
bean instance. Option A can increase memory usage by maintaining more
objects in the cache, but could provide better response time if bean instances
are not generally accessed concurrently by multiple transactions.
- For Commit Option B (implies shared DB access), use Activate at = Once,
Load at = Transaction. Option B can increase memory usage by
maintaining more objects in the cache. However, because each
transaction creates its own copy of an object, there can be multiple copies of
an instance in memory at any given time (one per transaction), requiring that
the database be accessed at each transaction. If an enterprise bean
contains a significant number of calls to the ejbActivate function, using
Option B can be beneficial because the required object is already in the
cache. Otherwise, this option does not provide significant benefit over
Option A.
- For Commit Option C (implies shared DB access), use Activate at =
Transaction and Load at = Transaction. This option can reduce memory
usage by maintaining fewer objects in the cache, however, there can be
multiple copies of an instance in memory at any given time (one per
transaction). This option can reduce transaction contention for
enterprise bean instances that are accessed concurrently but not
updated.
- Locale location
- Specifies the language used when the enterprise bean retrieves and
displays message catalogs: the local language of the client that invoked
the bean method or the local language of the server where the bean is
running. Valid values are server and caller.
- Local Transactions -- Boundary
- Specifies when a local transaction begins. The default behavior is
that the local transaction begins when the method begins and ends when the
method ends.
- Local Transactions -- Unresolved action
- Specifies the action the container must take if resources are uncommitted
by an application in a local transaction. A local transaction context
is created when a method executes in what the EJB specification refers to as
an unspecified transaction context. Valid values are Rollback and
Commit. The default is Rollback.
- Local Relationship Roles - Name
- Information is not available.
- Local Relationship Roles - Source EJB Name
- Information is not available.
- Local Relationship Roles - is Forward
- Information is not available.
- Local Relationship Roles - is Navigable
- Information is not available.
- JNDI name
- Specifies the JNDI name of the bean's home interface. This is
the name under which the enterprise bean's home interface is registered
and therefore is the name that must be specified when an EJB client does a
lookup of the home interface.
- Data Source - JNDI name
- Specifies the JNDI name for the bean's data source.
- Default Authorization - User ID
- Specifies the default user ID for connecting to a data source.
- Default Authorization - Password
- Specifies the default password for connecting to a data source.
|
|