Reputation: 49
Which version of Springdoc (springdoc-openapi
) is compatible with Spring Boot 3.2.8?
I'm unable to open Swagger UI via localhost.
I have a project that runs on Spring Boot 3.2.8 and cannot downgrade to the version below that.
The dependency which I'm using in pom.xml is springdoc-openapi-ui
version 1.7.0.
Upvotes: 3
Views: 4106
Reputation: 31
springdoc-openapi : 2.3.x - 2.5.x is compatible with spring boot 3.2.x
You can find the compatibility matrix of springdoc-openapi with spring-boot from link below :
compatibility matrix of springdoc-openapi with spring-boot
Upvotes: 3
Reputation: 16539
Simple answer: springdoc-openapi
version 2.x will be only supported for Spring Boot 3.x.
Just add these dependencies given below if it's a Maven project:
<dependency>
<groupId>org.springdoc</groupId>
<artifactId>springdoc-openapi-starter-webmvc-ui</artifactId>
<version>2.6.0</version>
</dependency>
<dependency>
<groupId>org.springdoc</groupId>
<artifactId>springdoc-openapi-starter-webmvc-api</artifactId>
<version>2.6.0</version>
</dependency>
Add this line in application.properties:
springdoc.swagger-ui.path=/swagger-ui.html
It will work.
Output:
Read the V1 docs & V2 docs. It's mentioned properly.
Upvotes: 1