PR for openapi-generator-maven-plugin inputSpec -- Allow jar: URLs#18576
PR for openapi-generator-maven-plugin inputSpec -- Allow jar: URLs#18576wing328 merged 10 commits intoOpenAPITools:masterfrom
Conversation
bf30b60 to
0d43b21
Compare
|
can you please also add a test or 2 in https://github.com/OpenAPITools/openapi-generator/blob/master/.github/workflows/maven-plugin-tests.yaml#L44 ? |
Will do so. I have to fix other tests, also. I have so issues to run the build locally. |
81144af to
3ee767d
Compare
E.g., jar:jar-specific-uri!/spec.yml.
specifications: * URLs of the form jar:jar-specific-uri!/spec.yaml * Resources on the compilation classpath in addition to the existing FILE test case.
else it is a remote URL && url is not empty
69c1d77 to
904c663
Compare
|
@wing328 instead of adding another pom to https://github.com/OpenAPITools/openapi-generator/blob/master/.github/workflows/maven-plugin-tests.yaml#L44 , I've extended https://github.com/OpenAPITools/openapi-generator/blob/master/modules/openapi-generator-maven-plugin/examples/java-client.xml with another There are also tests in |
| <dependency> | ||
| <groupId>org.apache.maven</groupId> | ||
| <artifactId>maven-resolver-provider</artifactId> | ||
| <version>3.9.4</version> |
There was a problem hiding this comment.
can w use 3.9.6 instead which is the latest stable 3.x version?
There was a problem hiding this comment.
I've aligned it with other maven dependencies. Should I update other references to 3.9.6, also? Or just use a property to reference same maven version and update in another PR?
https://github.com/apache/maven/blob/master/pom.xml#L308
There was a problem hiding this comment.
Updated maven dependencies to 3.9.6 via same property. Now it is clearer that they belong together updated.
Was introduced with OpenAPITools#7587 could be removed with OpenAPITools#10544
these artifacts are referenced by same ${project.version} in https://github.com/apache/maven/blob/master/pom.xml
|
@parenko thanks for the PR, which has been merged into the master. |
This is a PR in response to #10016. It changes
<inputSpec/>processing to:In the case that a compilation classpath resource is specified, the resource URL is passed to the swagger-parser OpenAPIV3Parser instead of the
<inputSpec/>string since the OpenAPIV3Parser does not have access to the Maven compilation classpath. This requires swagger-api/swagger-parser#1592 and swagger-api/swagger-parser#1593.modules/openapi-generator-maven-plugin/src/test/java/org/openapitools/codegen/plugin/CodeGenMojoTest.java has been expanded to include tests for resource and URL input specs.
(This is a copy of PR #10037. I've rebased original branch on master, fixed merge conflicts and removed swagger-parser 2.0.28-SNAPSHOT since 2.1.19 is used now)
CC @wing328, @jimschubert