Check reindex status API

[experimental] This functionality is experimental and may be changed or removed completely in a future release. Elastic will take a best effort approach to fix any issues, but experimental features are not subject to the support SLA of official GA features. Check the status of the reindex operation.

Check the status of the reindex operation.

Request

GET <kibana host>:<port>/api/upgrade_assistant/reindex/myIndex

Response codes

200

Indicates a successful call.

Example

The API returns the following:

  1. {
  2. "reindexOp": {
  3. "indexName": ".ml-state",
  4. "newIndexName": ".reindexed-v7-ml-state",
  5. "status": 0,
  6. "lastCompletedStep": 40,
  7. "reindexTaskId": "QprwvTMzRQ2MLWOW22oQ4Q:11819",
  8. "reindexTaskPercComplete": 0.3,
  9. "errorMessage": null
  10. },
  11. "warnings": [],
  12. "hasRequiredPrivileges": true
  13. }

Name of the new index that is being created.

Current status of the reindex. For details, see Status codes.

Last successfully completed step of the reindex. For details, see Step codes table.

Task ID of the reindex task in Elasticsearch. Only present if reindexing has started.

Percentage of how far the reindexing task in Elasticsearch has progressed, in decimal from from 0 to 1.

Error that caused the reindex to fail, if it failed.

An array of any warning codes explaining what changes are required for this reindex. For details, see Warning codes.

Specifies if the user has sufficient privileges to reindex this index. When security is unavailable or disables, returns true.

Status codes

0

In progress

1

Completed

2

Failed

3

Paused

If the Kibana node that started the reindex is shutdown or restarted, the reindex goes into a paused state after some time. To resume the reindex, you must submit a new POST request to the /api/upgrade_assistant/reindex/<indexName> endpoint.

4

Cancelled

Step codes

0

The reindex operation has been created in Kibana.

10

The index group services stopped. Only applies to some system indices.

20

The index is set to readonly.

30

The new destination index has been created.

40

The reindex task in Elasticsearch has started.

50

The reindex task in Elasticsearch has completed.

60

Aliases were created to point to the new index, and the old index has been deleted.

70

The index group services have resumed. Only applies to some system indices.

Warning codes

0

Specifies to remove the _all meta field.

1

Specifies to convert any coerced boolean values in the source document. For example, yes, 1, and off.

2

Specifies to convert documents to support Elastic Common Schema. Only applies to APM indices created in 6.x.

Most Popular