Product Documentation

c-treeDB API API for C

Previous Topic

Next Topic

ctdbCheckIndexBackgroundLoad

Check the status of the background index loader for the specified table.

Declaration

CTDBRET ctdbDECL ctdbCheckIndexBackgroundLoad(CTHANDLE Handle, pBGLDINF status)

Description

This function can be used to monitor the status of the index loading on tables. See CTINDEX_BCKLOAD.

  • Handle [IN] - Table handle.
  • status [OUT] - status information.

Background key loading can improve performance when adding new indexes. A new background loading mode can be OR-d in with an existing key mode from a ctdbAddIndex (ctdbAddIndex, ctdbAddIndex)() call indicating initial index loading must be done in the background.

Once ctdbAddIndex() is called, ctdbAlterTable() initiates the changes to the file and begins the load once the new index is successfully created.

Check the status of index loading with the new ctdbCheckIndexBackgroundLoad() (ctdbCheckIndexBackgroundLoad, ctdbCheckIndexBackgroundLoad) API, useful for monitoring index loading on tables.

Returns

Returns CTDBRET_OK on success.

TOCIndex