smui icon indicating copy to clipboard operation
smui copied to clipboard

add better error messaging upon rules collection creation

Open depahelix2021 opened this issue 3 years ago • 2 comments

If you do not provide both names, there should be a clear error message that says as much.

If a 500 Internal Server Error comes back, surface that to the user and hint that it is most likely because they are trying to create a rules collection for a Solr collection that already has one attached to it.

depahelix2021 avatar May 24 '22 17:05 depahelix2021

Error handling makes sense, however I wonder if there is also a better response code that the API could provide?

epugh avatar May 24 '22 19:05 epugh

Now instead of a 500, the API catches that issue with SQL constraints not allowing the addition, and returns back a more normal BadRequest.

depahelix2021 avatar May 24 '22 19:05 depahelix2021