Skip to main content

Rebuild a search index

POST 

/pipelines/:pipeline_id/search-indexers/:indexer_id/rebuild

Rebuilds the database indexes of a search index in the background, one after the other, with a concurrent reindex. Searches and document processing continue on the existing copy of each database index during the rebuild. A rebuild reclaims the space that the entries of deleted and replaced fragments occupy, and improves a vector index that was first built on few fragments. The request has no body.

The response returns as soon as the rebuild starts. While the rebuild runs, the rebuild field of the search index reports the database index, the phase and the progress, and the rebuild is complete when rebuild is null. Only one rebuild or distance index build runs on a search index at a time.

Permissions. Write on the pipeline.

Rebuild shows the request.

Request​

Responses​

The rebuild started. The body holds the identifier of the search index and the names of the database indexes that the rebuild replaces.