[JAXRS-spec] Add option useSwaggerAnnotations (for MicroProfile-OpenAPI)#813
[JAXRS-spec] Add option useSwaggerAnnotations (for MicroProfile-OpenAPI)#813jmini merged 14 commits intoOpenAPITools:masterfrom michbeck100:filter_swagger_annotations
Conversation
…in generated code. By default annotations are generated.
…(..) is too early
# Conflicts: # modules/openapi-generator/src/main/java/org/openapitools/codegen/languages/JavaJAXRSSpecServerCodegen.java
|
Thank you for this PR. I like your approach.
The Shippable CI Job ensure that the content of the
|
|
I just ran |
|
I once generated this table: https://github.com/OpenAPITools/openapi-generator/wiki/Samples-folder#scripts (might be outdated) I have computed the list for your by looking at the Shippable error report. If you have time (takes some minutes), you can also run |
|
I had to fix some missing imports in efe7014. BTW: it seems that before 82eba8d this wan't working at all. And i don't really know what this is good for. |
|
Thank you a lot for this contribution |
|
@michbeck100 thanks for the enhancement, which is included in the v3.2.2 stable release: https://twitter.com/oas_generator/status/1032252335131512832 |
PR checklist
./bin/to update Petstore sample so that CIs can verify the change. (For instance, only need to run./bin/{LANG}-petstore.shand./bin/security/{LANG}-petstore.shif updating the {LANG} (e.g. php, ruby, python, etc) code generator or {LANG} client's mustache templates). Windows batch files can be found in.\bin\windows\.master,3.3.x,4.0.x. Default:master.Description of the PR
The Microprofile OpenAPI specification allows to have just a static openapi.yaml file in the application module’s root
META-INFfolder (see here). So this PR adds an additional property "useSwaggerAnnotations" that doesn't generate the Swagger annotations if set to false (default value is true for backward compatibility).This way you can easily generate code that conforms to contract first and is compliant with the microprofile openapi specification