-
Notifications
You must be signed in to change notification settings - Fork 579
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
pandaproxy: Improve header validation #3664
Conversation
348ddc0
to
67215b0
Compare
Looks like something is returning JSON as a valid content-type and breaking one of the tests. |
Ensure consistency between request validation and Swagger UI command generation * Requests without a body do not require `Content-Type` validation * Swagger: Remove 'consumes' for empty body requests * Swagger: Ensure 'produces' for all endpoints to prevent SwaggerUI generating `application/json` Signed-off-by: Ben Pope <ben@vectorized.io>
67215b0
to
c6125c3
Compare
The test was checking that the content type is specifically rejected. I see no need. |
Is it really about the empty body or is it more about GET vs {POST,PUT}? |
There are I imagine it's possible that It may even be possible to change the query parameters based on the |
Cover letter
Ensure consistency between request validation and Swagger UI command generation
Content-Type
validationconsumes
for empty body requestsproduces
for all endpoints to prevent SwaggerUI generatingapplication/json
Swagger documented on SwaggerHub
Signed-off-by: Ben Pope ben@vectorized.io
Release notes
Improvements