An entity object

From
Jump to navigation Jump to search

A typical entity object has the following characteristics:

  • Provides an object view of data in the database.
  • Allows shared access from multiple users.
  • Can be long-lived (lives as long as the data in the database).
  • The entity, its primary key, and its remote reference survive the crash of the EJB container. If the state of an entity was being updated by a transaction at the time the container crashed, the entity’s state is automatically reset to the state of the last committed transaction. The crash is not fully transparent to the client—the client may receive an exception if it calls an entity in a container that has experienced a crash.

A typical EJB container and server provide a scalable runtime environment for a large number of concurrently active entity objects.