You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
When ProblemDetailsMiddleware catch exception (for example MySQL connection problem) then we cannot put code of this exception and what is worse put message from exception to detail.
I have many services with apigility and I need to care about leaking implementation details by my self, but we can handle it out-of-box.
The text was updated successfully, but these errors were encountered:
Just to clarify, the problem you have is with using the exception code for the HTTP status, correct?
Right now, I check to see if the status is within an acceptable range for HTTP statuses (100-599); this should likely be shrunk to only allow statuses between 400 and 599, which I can do immediately. If the exception falls outside that range, the component will use status 500 always.
My question: how many exceptions have you seen or used that use exception codes in the 400-599 integer range that were not deliberately thrown with the intention of allowing the code to be used as the HTTP status? Essentially, is this a problem? I really want to know; I rarely see exception codes other than zero, except coming from extensions, and those from extensions are usually 5 or more digits, making them fall well outside normal HTTP status ranges. If you can provide examples otherwise, I'd love to see them.
I worried about this new package introducing same seriously issue like in zfcampus/zf-api-problem#27
When
ProblemDetailsMiddleware
catch exception (for example MySQL connection problem) then we cannot put code of this exception and what is worse put message from exception todetail
.I have many services with apigility and I need to care about leaking implementation details by my self, but we can handle it out-of-box.
The text was updated successfully, but these errors were encountered: