Shared-Nothing Persistence Concepts

Use a unique name for each member that is joining the space. This is used to uniquely identify the persistence files.

Define a data store for each node that is joining as a seeder. The data store must be an existing directory name (with full path) that ActiveSpaces has permissions to read and write to.

You can do this by:

  • Using the MemberDef object and calling the tibasMemberDef_SetDataStore() function.
  • Setting the AS_DATA_STORE environment variable to the directory required before starting the client program or as-agent.
  • With the as-agent, using the -data_store <directory name with path> CLI command.

    When you are using the -data_store option with the as-agent command, such as as-agent -datastore "c:/abc/tmp"" ensure that you specify the absolute path to a directory. Also ensure that the datastore has write permissions on the directory.

    The data store directory can be different or same for each node (seeder). If it is the same, ActiveSpaces creates the required subdirectory structure based on the metaspace name, space name, and member name. Each file has the member name and a timestamp embedded in its name.

    Do not rename the files that are created by the persistence operation.

For code examples showing how to set up shared-nothing persistence, refer to ASPersistence2.c in the /examples directory.
Note: With shared-nothing and limited capacity, running a query on a field that is not indexed could return partial results. Before you query on a field, add an index on the field.