-
Notifications
You must be signed in to change notification settings - Fork 2.7k
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
Quarkus OpenAPI Generated documentation for @BeanParam does not reflect @Parameter if you are using a setter #8415
Comments
/cc @EricWittmann |
@sean-scott-lr , do you have the |
Here is an example of what we have:
|
@sean-scott-lr What about
|
@sean-scott-lr , please try:
|
@MikeEdgar Yes that does work. Was I misusing the API? |
@r00ta That works too. Are there docs somewhere I missed that show the usage scenarios? |
@r00ta's solution will also work. The |
@MikeEdgar @r00ta Thank you |
@r00ta Note, that in your solution with the @QueryParam in the setter works for both documentation and functionality. However, with @PathParam my code is no longer functional. ( the parameter is not set ). |
Can we close this one ? @MikeEdgar ? @sean-scott-lr ? |
@phillip-kruger - this was likely fixed with smallrye/smallrye-open-api#333 or smallrye/smallrye-open-api#293. |
Describe the bug
Quarkus OpenAPI Generated documentation for
@BeanParam
does not reflect the information coded in an@Parameter
annotation if you are using a setter.It appears that you must annotate a member variable instead of a setter method with Both
@QueryParam
and@Parameter
in order for the API Doc to work properly. However, in our case, we are setting the value into a delegate and this workaround will not work for us.Expected behavior
The API doc that is produced, contains the information that exists in the annotations.
Actual behavior
The @QueryParam shows up in the documentation, with no additional information.
To Reproduce
Steps to reproduce the behavior:
@QueryParam
and@Parameter
( description , required = true, examples, etc )Configuration
# Add your application.properties here, if applicable.
Screenshots
(If applicable, add screenshots to help explain your problem.)
Environment (please complete the following information):
Environment (please complete the following information):
Output of
uname -a
orver
:Darwin XXXXX 19.4.0 Darwin Kernel Version 19.4.0: Wed Mar 4 22:28:40 PST 2020; root:xnu-6153.101.6~15/RELEASE_X86_64 x86_64
Output of
java -version
:openjdk version "11.0.6" 2020-01-14
OpenJDK Runtime Environment AdoptOpenJDK (build 11.0.6+10)
OpenJDK 64-Bit Server VM AdoptOpenJDK (build 11.0.6+10, mixed mode)
GraalVM version (if different from Java):
Quarkus version or git rev:
1.3.1.Final
Build tool (ie. output of
mvnw --version
orgradlew --version
):Apache Maven 3.6.3 (cecedd343002696d0abb50b32b541b8a6ba2883f)
Additional context
(Add any other context about the problem here.)
The text was updated successfully, but these errors were encountered: