为了验证我们的Spring Boot应用程序的启动和关闭能力,我们希望配置一个startup.log和shutdown.log,以捕获引导和关闭应用程序的事件。
启动时,我们需要记录以下所有内容:
启动时,我们需要记录以下所有内容:
Root WebApplicationContext: initialization completed in {x} ms
关机时需要关闭所有内容:
Closing org.springframework.boot.context.embedded.AnnotationConfigEmbeddedWebApplicationContext@53bd8fca: startup date [Wed Aug 19 09:47:10 PDT 2015]; root of context hierarchy
到最后。
这是特定于容器的吗?(Tomcat vs Jetty vs Undertow)