标签:# springfox

修复 Spring 2.3.x 升级到更新版本出现的跨域问题

异常提示:

When allowCredentials is true, allowedOrigins cannot contain the special value "*" since that cannot be set on the "Access-Control-Allow-Origin" response header. To allow credentials to a set of origins, list them explicitly or consider using "allowedOriginPatterns" instead.

#解决办法:
跨域配置报错,将.allowedOrigins替换成.allowedOriginPatterns即可。

修复 SpringFox 3.0.0 不兼容 SpringBoot 2.6.4 的问题

异常提示:

Failed to start bean 'documentationPluginsBootstrapper'; nested exception is java.lang.NullPointerException

原因分析:

SpringFox 3.0.0 不兼容 SpringBoot 2.6.4

解决方案: