访问eureka 显示xml

两种解决方式:

方式一:(我是通过此方式解决的)

一个博客“http://blog.csdn.net/l5764773160/article/details/77483730”,他的解决方案是:
将项目中依赖的freemarker-2.3.25-incubating.jar版本从本地maven仓库中删除,再maven update 项目。

 方式二:

另个一解决方案:“https://stackoverflow.com/questions/43314822/spring-eureka-dashboard-returns-xml-on-wildfly”,有个人的回答是:

freemarker的viewResolver没有在spring-cloud-netflix-eureka-server-1.3.1.RELEASE.jar中找到模板”

于是,在application.yml文件中,增加

spring: freemarker: prefer-file-system-access: false

分析:此问题出现可能跟spring cloud 版本有关。

猜你喜欢

转载自www.cnblogs.com/anenyang/p/10886677.html
今日推荐