Now, create a new replication rule 'A' and try to delete replication rule 'B'. Here we could see that there is a successful response in deleting a non-existing replication rule.
curl -Method POST -Uri "http://localhost:9201/_plugins/_replication/_autofollow?pretty" -H @{'Content-Typ
e' = 'application/json'} -body '{"leader_alias":"leader", "name": "test", "pattern": "test-*"}'
StatusCode : 200
StatusDescription : OK
Content : {
"acknowledged" : true
}
Hi,
Deletion of any non-existing autofollow replication rule gives "Acknowledge: true" response.
How can one reproduce the bug?
If any replication rule is tried to be deleted before creation of the first replication rule, it throws ResourceNotFoundException.
ex:
Directly delete the autofollow replication rule before creation of any autofollow rule.
Now, create a new replication rule 'A' and try to delete replication rule 'B'. Here we could see that there is a successful response in deleting a non-existing replication rule.
What is the expected behavior? Deletion of any non-existing replication should throw ResourceNotFoundException at the API level interaction.