Spring Tomcat未重定向到index.html

Spring Tomcat未重定向到index.html,spring,spring-boot,kotlin,tomcat,Spring,Spring Boot,Kotlin,Tomcat,出于某种原因,我部署到tomcat中的spring boot war没有为index.html中的站点根请求提供服务。(index.html位于上下文根目录下) 当我使用一个可执行的war时,一切正常-自动加载index.html。出于某种原因,当我将同一个war部署到tomcat并导航到时,我得到了SpringBoot的404页面。不过,这很好。我在可执行war和tomcat日志的启动日志中看到了“o.s.b.a.w.s.WelcomePageHandlerMapping:Adding wel

出于某种原因,我部署到tomcat中的spring boot war没有为index.html中的站点根请求提供服务。(index.html位于上下文根目录下)

当我使用一个可执行的war时,一切正常-自动加载index.html。出于某种原因,当我将同一个war部署到tomcat并导航到时,我得到了SpringBoot的404页面。不过,这很好。我在可执行war和tomcat日志的启动日志中看到了“o.s.b.a.w.s.WelcomePageHandlerMapping:Adding welcome page:ServletContext resource[/index.html]”。然而,在tomcat的访问日志中,有一个404,没有重定向:
GET/HTTP/2.0“404286

My web.xml具有以下内容,似乎在任何地方都不会被覆盖

Tomcat(404)
请检查该链接,它可能会有所帮助-@NeerajBenjwal没有任何相关内容-该部分流程工作正常。
<welcome-file-list>
  <welcome-file>index.html</welcome-file>
  <welcome-file>index.htm</welcome-file>
  <welcome-file>index.jsp</welcome-file>
</welcome-file-list>
2020-09-23 01:34:21.348 TRACE 11076 --- [nio-8443-exec-3] o.s.web.servlet.DispatcherServlet        : GET "/", parameters={}, headers={masked} in DispatcherServlet 'dispatcherServlet'
2020-09-23 01:34:21.353 TRACE 11076 --- [nio-8443-exec-3] o.s.b.a.w.s.WelcomePageHandlerMapping    : Mapped to HandlerExecutionChain with [ParameterizableViewController [view="forward:index.html"]] and 3 interceptors
2020-09-23 01:34:21.362 TRACE 11076 --- [nio-8443-exec-3] o.s.b.f.s.DefaultListableBeanFactory     : Invoking afterPropertiesSet() on bean with name 'forward:'
2020-09-23 01:34:21.362 TRACE 11076 --- [nio-8443-exec-3] o.s.b.f.s.DefaultListableBeanFactory     : Returning cached instance of singleton bean 'metaDataSourceAdvisor'
2020-09-23 01:29:05.816 TRACE 10413 --- [apr-8443-exec-1] o.s.web.servlet.DispatcherServlet        : GET "/", parameters={}, headers={masked} in DispatcherServlet 'dispatcherServlet'
2020-09-23 01:29:05.818 TRACE 10413 --- [apr-8443-exec-1] o.s.w.s.handler.SimpleUrlHandlerMapping  : Mapped to HandlerExecutionChain with [ResourceHttpRequestHandler ["classpath:/META-INF/resources/", "classpath:/resources/", "classpath:/static/", "classpath:/public/", "/"]] and 3 interceptors
2020-09-23 01:29:05.818 DEBUG 10413 --- [apr-8443-exec-1] o.s.w.s.r.ResourceHttpRequestHandler     : Resource not found
2020-09-23 01:29:05.818 DEBUG 10413 --- [apr-8443-exec-1] w.c.HttpSessionSecurityContextRepository : SecurityContext is empty or contents are anonymous - context will not be stored in HttpSession.
2020-09-23 01:29:05.818 TRACE 10413 --- [apr-8443-exec-1] o.s.web.servlet.DispatcherServlet        : No view rendering, null ModelAndView returned.
2020-09-23 01:29:05.818 DEBUG 10413 --- [apr-8443-exec-1] o.s.web.servlet.DispatcherServlet        : Completed 404 NOT_FOUND, headers={masked}