I'm doing Elasticsearch reindexing as a multistep process using the JavaScript client library:
I need to wait for the 1st step to complete before doing the next steps. Is there an Elasticsearch endpoint I can poll to find out when the clone is complete?
If I recall correctly, there is no specific endpoint for monitoring the clone API. But you can use the cat recovery api
POST old/_clone/new
# This call is to be made until it returns nothing
GET _cat/recovery/new?active_only=true&format=json
DELETE old