There has been post similar to my issue but I have all the correct dependentcies. I also have another application that is working with swagger 3 that I just updated to spring 2 -> 3. I am struggling to figure out why this very small helper repo cannot resolve swagger 3.
maven pom.xml
<springfox-swagger.version>3.0.0</springfox-swagger.version>
<swagger.version>2.2.15</swagger.version>
<springdoc.version>2.5.0</springdoc.version>
<!-- ................................................................= -->
<!-- Springfox -->
<!-- ................................................................= -->
<dependency>
<groupId>io.springfox</groupId>
<artifactId>springfox-swagger2</artifactId>
</dependency>
<!-- ................................................................= -->
<!-- Swagger -->
<!-- ................................................................= -->
<dependency>
<groupId>io.swagger.core.v3</groupId>
<artifactId>swagger-annotations</artifactId>
<version>${swagger.version}</version>
</dependency>
<dependency>
<groupId>io.swagger.core.v3</groupId>
<artifactId>swagger-models</artifactId>
<version>${swagger.version}</version>
</dependency>
<dependency>
<groupId>org.springdoc</groupId>
<artifactId>springdoc-openapi-starter-webmvc-ui</artifactId>
<version>${springdoc.version}</version>
</dependency>
The app fails because classes that are generated via openapi cannot resolve swagger.
Has anyone has a similar experience?
SpringFox hasn't been updated since June 2020, and its latest version, 3.0.0, supports Spring Boot 2.0.0.
You might need to switch to SpringDoc, which is compatible with Spring Boot 3.0.0 and onwards.
This migration guide will be a great help to you
implementation group: 'org.springdoc', name: 'springdoc-openapi-starter-webmvc-ui', version: '2.2.0'
<dependency>
<groupId>org.springdoc</groupId>
<artifactId>springdoc-openapi-starter-webmvc-ui</artifactId>
<version>2.2.0</version>
</dependency>
The following posts seem to be experiencing similar things as you are.