springfox swagger2 实现接口不生成API的问题

使用swagger2  controller层实现接口后,无法生成API,

原因: spring 动态代理,实现接口时使用JDK, 其他情况使用cglib

解决方式:强制使用cglib

springboot中application.properties中配置如下:

#动态代理配置
spring.aop.auto=true
spring.aop.proxy-target-class=true
 

猜你喜欢

转载自blog.csdn.net/u011943534/article/details/79899029
今日推荐