Closed JohnNiang closed 11 hours ago
2.17.0-SNAPSHOT
Currently, if there is a conflict in the operation, Halo will respond with status 500, which is a confusion for end users. e.g.:
{ "type": "about:blank", "title": "Internal Server Error", "status": 500, "detail": "Something went wrong, please try again later.", "instance": "http://halo:8090/apis/api.console.halo.run/v1alpha1/users/bnmJqS/password", "requestId": "f3fea404-10", "timestamp": "2024-06-21T01:49:03.746356448Z" }
IMO, it's more reasonable to respond 409 (Conflict) in that situation. e.g.:
{ "type": "https://www.halo.run/probs/operation-conflict", "title": "Operation Conflict", "status": 409, "detail": "Operation conflict detected, please try again.", "instance": "http://halo:8090/apis/api.console.halo.run/v1alpha1/users/bnmJqS/password", "requestId": "f3fea404-10", "timestamp": "2024-06-21T01:49:03.746356448Z" }
/kind improvement /area core /milestone 2.18.x
/assign
Your current Halo version
2.17.0-SNAPSHOT
Describe this feature
Currently, if there is a conflict in the operation, Halo will respond with status 500, which is a confusion for end users. e.g.:
IMO, it's more reasonable to respond 409 (Conflict) in that situation. e.g.:
Additional information
/kind improvement /area core /milestone 2.18.x