Defining a partitioned object

A partitioned object is a managed object with a partition mapper installed. An object is highly available if at least one replica node is defined for the partition. There is no difference in the behavior of Managed Objects when they have a partition mapper installed.

To add partitioned objects to an application, the following is required:

Partitioned object life cycle

Partitioned objects have the same life cycle as a non-partitioned managed object. See the section called “Managed object life cycle” for details. When a partitioned object is deleted any replica copies of the object are also deleted. See the section called “Distributed object life cycle” other details on distributed object life-cycle.

Restrictions

A partitioned managed object adds this additional restriction to a managed object definition (the section called “Restrictions”):

  • Any parent classes with keys must be abstract.

This restriction is audited when the Partition Mapper is installed (see Example 7.1, “Defining , installing, and clearing a partition mapper”). If the audit fails, a com.kabira.platform.ManagedClassError is thrown by the com.kabira.platform.highavailability.PartitionManager.setMapper(...) method.