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 used inside of @Components, the responseCode value of an @APIResponse is not usable from the operations where it is referenced. Using multiple @APIResponse annotations on a method with a ref to a global response results in a single default response.
My expectation as a user is that the response status from the global component should be known to the scanner and used as the key to the operation's responses map (via an implementation-specific field in APIResponseImpl). Specifying both responseCode and ref on the operation's annotation is possible, but results are undefined for other properties when ref is given, and it also results in repeated information.
@EricWittmann , @phillip-kruger - w.d.y.t.? I've already coded this, but wanted to hold off on a PR in case some additional discussion is needed or a different approach is possible that I'm not thinking of.
The text was updated successfully, but these errors were encountered:
I agree - I'll open up an issue over there later today. If we are good with implementing something here first, I'll go ahead and open the PRs for master and 2.0.x later today also.
When used inside of
@Components
, theresponseCode
value of an@APIResponse
is not usable from the operations where it is referenced. Using multiple@APIResponse
annotations on a method with aref
to a global response results in a singledefault
response.Example:
The resulting OpenAPI shows that the
404
status is "lost".My expectation as a user is that the response status from the global component should be known to the scanner and used as the key to the operation's
responses
map (via an implementation-specific field inAPIResponseImpl
). Specifying bothresponseCode
andref
on the operation's annotation is possible, but results are undefined for other properties whenref
is given, and it also results in repeated information.@EricWittmann , @phillip-kruger - w.d.y.t.? I've already coded this, but wanted to hold off on a PR in case some additional discussion is needed or a different approach is possible that I'm not thinking of.
The text was updated successfully, but these errors were encountered: