swagger-api / swagger-api/swagger-parser
V2 converter depends on javax not jakarta packages
Open
@frantuma is already working on this.
Since May 2, 2024.
- Dominant language
- Java
- Stars
- 867
- Forks
- 560
- Avg merge
- 2d 21h
- Merged PRs (30d)
- 7
Description
If you try to use the converter in a modern Jakarta-packaged application you get problems with duplicate classes in swagger-core and swagger-annotations. The workaround is to exclude them and depend explicitly on the jakarta-based versions, e.g:
<dependency>
<groupId>io.swagger.core.v3</groupId>
<artifactId>swagger-core-jakarta</artifactId>
<version>2.2.9</version>
</dependency>
<dependency>
<groupId>io.swagger.parser.v3</groupId>
<artifactId>swagger-parser-v2-converter</artifactId>
<version>2.1.16</version>
<exclusions>
<exclusion>
<groupId>io.swagger.core.v3</groupId>
<artifactId>swagger-core</artifactId>
</exclusion>
<exclusion>
<groupId>io.swagger.core.v3</groupId>
<artifactId>swagger-models</artifactId>
</exclusion>
</exclusions>
</dependency>
This is kind of annoying, even though it's a problem that is created by the core libraries. It seems we need to have a "-jakarta" version of the converter library too?
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Assessment
This issue has not been assessed yet.