uCosminexus Application Server, Application Setup Guide
Entity Bean attribute file
Execute the following command to acquire an Entity Bean attribute file:
cjgetappprop [server-name] [-nameserver provider-URLL] -name J2EE application-name -type ejb -resname EJB-JAR-display-name/Entity-Bean-display-name -c <path-of-the-Entity-Bean-attribute-file |
cjgetappprop MyServer -name adder -type ejb -resname account/MyAccoub -c C:\home\adder_ejb.xml
Execute the following command to apply the values of the Entity Bean attribute file:
cjsetappprop [server-name] [-nameserver provider-URL] -name J2EE application-name -type ejb -resname EJB-JAR-display-name/Entity-Bean-display-name-c path-of-the-Entity-Bean-attribute-file |
cjsetappprop MyServer -name adder -type ejb -resname account/MyAccoub -c C:\home\adder_ejb.xml
The method of defining CMP differs based on whether the primary key is a single primary key or a compound primary key.
You set the properties for a single primary key.
Check the persistence management type (<persistence-type>). In the case of CMP Entity Bean, 'Container' is set.
The following table describes the property settings for a single primary key:
| Items | Mandatory | Corresponding tags |
|---|---|---|
| Primary key class#1 | Y | <prim-key-class> |
| Scope of reentrant | Y | <reentrant> |
| Description of the persistence management field | O | <cmp-field> - <description> |
| Field name of the persistence management field#2 | O | <cmp-field> - <field-name> |
| Field name of the primary key field | O | <primkey-field> |
For details on the property settings, see 3.5.1 Contents of the Entity Bean property file in the uCosminexus Application Server Application and Resource Definition Reference Guide.
You set the properties for a compound primary key.
Check the persistence management type (<persistence-type>). In the case of a CMP Entity Bean, 'Container' is set.
The following table describes the property settings for a compound primary key:
| Items | Mandatory | Corresponding tags |
|---|---|---|
| Primary key class#1 | Y | <prim-key-class> |
| Scope of reentrant | Y | <reentrant> |
| Description of the persistence management field | O | <cmp-field> - <description> |
| Field name of the persistence management field#2 | O | <cmp-field> - <field-name> |
For details on the property settings, see 3.5.1 Contents of the Entity Bean property file in the uCosminexus Application Server Application and Resource Definition Reference Guide.
All Rights Reserved. Copyright (C) 2013, Hitachi, Ltd.