tibasSpaceDef_SetPersisted()

Specifies whether a specified space is persistent and uses shard all persistence.

Declaration

tibas_status tibasSpaceDef_SetPersisted(
    tibasSpaceDef spaceDef,
    tibas_boolean persisted)

Parameters

Parameter Description
spaceDef The TIBCO ActiveSpaces entity on which the function is invoked.
persisted Whether or not the space is persistent.

If you set this argument to TIBAS_TRUE, the persistence type for the space is set to shared all persistence (TIBAS_PERSISTENCE_SHARED_ALL).

Remarks

Use the tibasSpaceDef_SetPersisted() function to specify whether the specified space uses shared all persistence.

If you specify TIBAS_TRUE for the persisted parameter, the space is persistent and will need to have at least one persister registered in order to be ready. The default is TIBAS_FALSE.

If you set the persisted argument to TIBAS_TRUE, the persistence type for the space is set to shared all persistence (TIBAS_PERSISTENCE_SHARED_ALL).

To set up shared all persistence, you must create and register at least one persister—a space member that is responsible for saving data to local storage.

To create a persister, you call the tibasPersister_Create() function. This function creates a Persister object, which specifies functions provided by your application to read or write data depending on what state the space is in. You then register the persister by calling the tibasSpace_SetPersister() function.

For more information on implementing shared all persistence, see Shared All Persistence of the TIBCO ActiveSpaces Developer’s Guide.