WAS v8.5 > Develop applications > Develop EJB applications > Assemble EJB 2.1 enterprise beansSet the run time for CMP sequence groups
By designating container managed persistence (CMP) sequence groups for entity beans, we can prevent certain types of database-related exceptions during the run time of custom EJB application. Specify in each group the order in which the beans update your relational database tables.
When you define a sequence group, you designate it as one of two types:
- RI_INSERT, for setting a bean persistence sequence to prevent database referential integrity (RI) violations. See the topic Sequence grouping for container-managed persistence in assembled EJB modules for more information.
- UPDATE_LOCK, for setting a bean persistence sequence to minimize exceptions resulting from optimistic concurrency control
Both types of sequence groups must be created after we have assembled the beans into an EJB module, before installing the application on the product. If we need to edit sequence groups, uninstall the application, make your changes with an assembly tool, and reinstall the application.
If we already selected or plan to use top-down mapping for mapping your enterprise beans to back-end data, we do not need to create a sequence group with an RI_INSERT type. WAS v8.5 does not generate an RI policy for the database schema that it creates when we select top-down mapping.
To learn how to complete this task see the assembly tool information center.
You are now ready to deploy custom EJB module or combine it with other modules into a Java EE application. For more information about these two tasks, see the topics Installing enterprise application files and Assembling Java EE client applications.
Related concepts:
Sequence grouping for container-managed persistence in assembled EJB modules
Related
Deploy enterprise applications
Install enterprise application files
Assemble applications