【发布时间】:2023-03-08 14:55:01
【问题描述】:
尝试从 Spring Boot 应用程序提供 index.html(位于 main/resources/static 下)时,我收到 HTTP 404 错误。但是,如果我从项目中删除基于 Jersey 的 JAX-RS 类,那么 http://localhost:8080/index.html 可以正常工作。
以下是主类
@SpringBootApplication
public class BootWebApplication {
public static void main(String[] args) {
SpringApplication.run(BootWebApplication.class, args);
}
}
我不确定我是否在这里遗漏了什么。
谢谢
【问题讨论】:
-
@emoleumassi 您能否详细说明兼容性问题?我们(Spring Boot 团队)对此一无所知。
-
@Andy Wilkinson 我已经对 Spring boot 和 jersey 有过不好的体验。查看我的帖子以获得更多解释:stackoverflow.com/questions/33026968/… 和 stackoverflow.com/questions/33000931/…
标签: spring-boot jersey jersey-2.0