在使用Thymeleaf作为视图技术的应用程序中访问swagger-ui.html

时间:2019-01-02 10:43:02

标签: spring-boot spring-security thymeleaf swagger-ui

我正在使用 thymeleaf-模板春季安全性在其余端点的api文档中使用 在Java中开发Web应用程序。应用。除了无法访问 swagger-ui.html 页面

的事实之外,其他所有东西都工作正常

我已经添加了过滤器来忽略Spring安全性中的大头针端点。我可以在浏览器中以json的形式访问v2/api-docs链接。但是,当我访问swagger-ui.html

时,出现以下错误
Whitelabel Error Page
This application has no explicit mapping for /error, so you are seeing this as a fallback.

Wed Jan 02 13:32:46 EAT 2019
There was an unexpected error (type=Internal Server Error, status=500).
Error resolving template "swagger-ui", template might not exist or might not be accessible by any of the configured Template Resolvers

0 个答案:

没有答案