-
Notifications
You must be signed in to change notification settings - Fork 2.8k
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
OpenAPI generation content-type mismatch #34700
Comments
sorry for the ping; @MikeEdgar @phillip-kruger would be nice if that could be looked into. This issue is still present in quarkus 3.4.1 |
I think the default content type is json ? Or is this just for jaxrs? @geoand ? |
I'll have a look at this a.s.a.p |
It's json in Quarkus when the return type is a POJO (or similar) |
Right, so the content type is correct even when using spring API we do this . The security is an issue though, I'll look at that |
O wait, only when pojo, not string. So this is an issue? Might event be an issue in jaxrs? |
This is also an issue for jax-rs. I am looking at a fix |
@cescoffier @phillip-kruger what about |
Probably yes. Same for Optional I guess |
Yes for JSON? |
Sorry, no I mean text. |
It's JSON now ... Will you create a PR to adjust that? |
Yes I will. |
Describe the bug
Let's consider the following endpoint (using spring compatibility, but it should not matter):
The generated OpenAPI document has the following content:
Two issues:
(2) leads to be unable to use the Swagger UI as it gets a 405 HTTP response.
Expected behavior
It should provide the right content type and no security description.
Actual behavior
See description.
How to Reproduce?
No response
Output of
uname -a
orver
No response
Output of
java -version
No response
GraalVM version (if different from Java)
No response
Quarkus version or git rev
No response
Build tool (ie. output of
mvnw --version
orgradlew --version
)No response
Additional information
No response
The text was updated successfully, but these errors were encountered: