Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

REST: Wrong error handling when deleting multiple components #851

Open
oheger-bosch opened this issue May 13, 2020 · 0 comments
Open

REST: Wrong error handling when deleting multiple components #851

oheger-bosch opened this issue May 13, 2020 · 0 comments
Labels
bug Something isn't working
Milestone

Comments

@oheger-bosch
Copy link
Contributor

The DELETE method on the components endpoint accepts multiple IDs for the components to be deleted. It returns a multi-status response, so that the caller can find out, which components could be deleted successfully. The current implementation, however, sends a 500 error response as soon as an error occurs when deleting components.

To reproduce, send a request to delete multiple components passing in some existing and at least one non-existing component IDs, e.g.:
DELETE /components/existingID1,existingID2,invalidID,existingID3

Response is a 500 error result. The existing components listed before the invalid ID have been deleted.

Expected result is a multi-status response containing success responses for the existing components and error responses for the invalid IDs.

@mcjaeger mcjaeger added the bug Something isn't working label May 27, 2020
@mcjaeger mcjaeger added this to the Backlog milestone Jul 1, 2020
nam-np added a commit to nam-np/sw360 that referenced this issue May 28, 2021
…sw360#851

Signed-off-by: Nguyen Phuong Nam <nam1.nguyenphuong@toshiba.co.jp>
mcjaeger added a commit that referenced this issue May 30, 2021
…iple-component

fix REST: Wrong error handling when deleting multiple components #851

tested-by:kumar.ravindra@siemens.com
review-by:kumar.ravindra@siemens.com
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants