[BUG] Generic error for persistent task on starting replication
What is the bug?
When start replication API fails due to failure in starting persistent task, the exact reason does not appear in the response. The response has a generic error message Timed out when waiting for persistent task after 1m
How can one reproduce the bug? Steps to reproduce the behavior:
- Create an index
testindex123and create an aliastestindexfor it on the leader cluster. - start replication with leader index name as
testindex123and follower index name astestindex - This should error out with above generic message.
What is the expected behavior?
The specific error while starting the replication should appear in the response. In the logs, the error is printed as cannot rename index [testindex123] into [testindex] because of conflict with an alias with the same name. This message should be bubbled up and returned in the response.
The simulation is for one scenario. All the scenarios should be listed for failure of starting persistent task and appropriate error message should be returned