Space Definition

You must define a space in the metaspace before it can be joined by applications and agents. The space is created when a member of the metaspace joins it and becomes the first member of the space. Conversely, the space is destroyed when the last member leaves it (and there are no more members of the space).

The space remains defined after all members have left, and can be reactivated if needed.

A space definition comprises two parts:
  • A set of space attributes and policies that define the space’s behavior and mode of deployment.
  • A set of field definitions that describe the format of the data that will be stored in the space.

The space definition is contained in a SpaceDef object that is defined in the ActiveSpaces API set. The SpaceDef object is either created from scratch by invoking the SpaceDef’s create() method, or returned by the metaspace or space’s getSpaceDef methods.

After a SpaceDef object has been created, you can set values for space attributes by specifying values for elements in the SpaceDef object.

Related reference