Skip to content
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

Initial OpenAPI support for Vert.x #10944

Merged
merged 1 commit into from
Jul 24, 2020
Merged

Initial OpenAPI support for Vert.x #10944

merged 1 commit into from
Jul 24, 2020

Conversation

phillip-kruger
Copy link
Member

@phillip-kruger phillip-kruger commented Jul 23, 2020

This PR adds initial support for Vert.x @Route to be included in the OpenAPI schema generation.

Fixes #10670

Fixes #8435

Signed-off-by: Phillip Kruger [email protected]

@boring-cyborg boring-cyborg bot added area/dependencies Pull requests that update a dependency file area/smallrye labels Jul 23, 2020
Copy link
Member

@cescoffier cescoffier left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM!

@gastaldi gastaldi added this to the 1.7.0 - master milestone Jul 23, 2020
@gastaldi gastaldi added the triage/waiting-for-ci Ready to merge when CI successfully finishes label Jul 23, 2020
@gastaldi
Copy link
Contributor

Fixes #10670

Fixes #8435

@mkouba
Copy link
Contributor

mkouba commented Jul 24, 2020

I'm sorry for my ignorance but what's the scope of the initial OpenAPI support for Vert.x? I mean there are no OpenAPI annotations in the tests, no docs...

@phillip-kruger
Copy link
Member Author

phillip-kruger commented Jul 24, 2020

Hi @mkouba - this is generating openapi from the new vertx @Route. At this point, the only OpenAPI annotations we add, is when we can not automatically figure out something, like for example on a void return. Most tests for this is in SmallRye. Happy to add more tests here if needed.

@mkouba
Copy link
Contributor

mkouba commented Jul 24, 2020

Ok, thanks Phillip!

So these are the important asserts 😄
https://github.com/quarkusio/quarkus/pull/10944/files#diff-720d8a9d7f47f0d3a806e32b5aefa169R37
https://github.com/quarkusio/quarkus/pull/10944/files#diff-d9dfefbe9d3dd228363dcd18f2656b79R39

How about the docs? Do you plan to send a follow-up PR and update the Reactive Routes guide?

@phillip-kruger
Copy link
Member Author

@mkouba - yes I can definitely update the docs as well. Happy to do it in this PR or a next. Might be easier in a next as this one is green already :)

@phillip-kruger
Copy link
Member Author

Here is the resources being test in SmallRye:

https://github.com/smallrye/smallrye-open-api/tree/master/extension-vertx/src/test/java/test/io/smallrye/openapi/runtime/scanner/resources

Any OpenAPI annotations should also work, but we can definably add more tests for that. It's get's fully tested in the Jax-rs tests, and the Spring and Vert.x only test their annotations.

@cescoffier cescoffier merged commit 4260d34 into quarkusio:master Jul 24, 2020
@phillip-kruger phillip-kruger deleted the vertx-open-api branch July 24, 2020 15:28
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area/dependencies Pull requests that update a dependency file area/smallrye triage/waiting-for-ci Ready to merge when CI successfully finishes
Projects
None yet
4 participants