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
refactor(ENTESB-12218): Replace Swagger with Apicurio model API #7161
refactor(ENTESB-12218): Replace Swagger with Apicurio model API #7161
Conversation
…pport multiple OpenAPI versions
Maven filtering is only available when running tests in Maven build. When running unit tests in IDE the tests fail because of missing resource filtering.
@christophd The bot could not transition the ticket automatically, please update this Jira ticket manually: https://issues.jboss.org/browse/ENTESB-12218 |
@@ -13,7 +13,7 @@ | |||
"connectorFactory": "io.syndesis.connector.rest.swagger.ConnectorFactory", | |||
"dependencies": [ | |||
{ | |||
"id": "@project.groupId@:@project.artifactId@:@project.version@", | |||
"id": "io.syndesis.connector:connector-rest-swagger:@project.version@", |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
hmm odd, works without issues in my IDE, is this a permanent change? Doesn't the @project.version@
influence the running of tests as well?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It should only work if you have run a Maven build before so Maven already applied the filtering in build output directory. When you do mvn clean
from time to time you should get the errors.
I think @project.version@ makes sense and the version is not verified in unit tests.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think my IDE is running Maven filtering on resources.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Lucky you 😃
import static java.util.Optional.ofNullable; | ||
|
||
/** | ||
* @author Christoph Deppisch |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I prefer code without @author
tags.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yeah it's in my IDE settings from ages ago. Perhaps I need to rethink
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks really good, nice refactor and cleanup effort!
...generator/src/main/java/io/syndesis/server/api/generator/swagger/BaseDataShapeGenerator.java
Outdated
Show resolved
Hide resolved
...generator/src/main/java/io/syndesis/server/api/generator/swagger/BaseDataShapeGenerator.java
Outdated
Show resolved
Hide resolved
...or/src/main/java/io/syndesis/server/api/generator/swagger/BaseOpenApiConnectorGenerator.java
Outdated
Show resolved
Hide resolved
...r/api-generator/src/main/java/io/syndesis/server/api/generator/swagger/OpenApiGenerator.java
Outdated
Show resolved
Hide resolved
...r/api-generator/src/main/java/io/syndesis/server/api/generator/swagger/OpenApiGenerator.java
Outdated
Show resolved
Hide resolved
@christophd The bot could not transition the ticket automatically, please update this Jira ticket manually: https://issues.jboss.org/browse/ENTESB-12218 |
This is the first step to replace Swagger model API with the Apicurio model API in order to support both version 2.x and 3.x of Open API specification at the same time.
This PR replaces the Swagger models API used in server-api-generator module.
Next step would be to add Open API 3.x support to that module in order to be able to process Open API 3 specifications.