DELETE /invdelete on primary node should probably throw REQUEST_INVALID instead of INVALID_OR_MISSING_PARM
Nobody has claimed this yet.
- Dominant language
- Java
- Stars
- 2
- Forks
- 0
- PR merge metrics
- No merged PRs in 30d
Description
The deleteObjectNode() method on ReplicationServiceHandler throws TException.INVALID_OR_MISSING_PARM if given a primary storage node, which translates to a 500 Internal Server Error.
Since this is a client (caller) error, rather than a problem with the server state, it would probably be more appropriate to return a 400 Bad Request by throwing TException.REQUEST_INVALID.
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start in replication-src/src/main/java/org/cdlib/mrt/replic/basic/service/ReplicationServiceHandler.java at deleteObjectNode(), which currently throws INVALID_OR_MISSING_PARM for a primary storage node. Verify the endpoint’s exception-to-HTTP mapping, then ensure this client error results in TException.REQUEST_INVALID and a 400 Bad Request response.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- java
- Domain
- api, backend
- Issue type
- Bug
- Difficulty
- 2/5
- Estimated time
- 1-3 hours
- Activity status
- Stale
- Clarity
- Clearly specified
- Newbie friendliness
- 45/100