Polish
This commit is contained in:
@@ -34,13 +34,10 @@ public class SampleTomcatApplication {
|
||||
|
||||
private static Log logger = LogFactory.getLog(SampleTomcatApplication.class);
|
||||
|
||||
public static void main(String[] args) throws Exception {
|
||||
SpringApplication.run(SampleTomcatApplication.class, args);
|
||||
}
|
||||
|
||||
@Bean
|
||||
protected ServletContextListener listener() {
|
||||
return new ServletContextListener() {
|
||||
|
||||
@Override
|
||||
public void contextInitialized(ServletContextEvent sce) {
|
||||
logger.info("ServletContext initialized");
|
||||
@@ -50,7 +47,12 @@ public class SampleTomcatApplication {
|
||||
public void contextDestroyed(ServletContextEvent sce) {
|
||||
logger.info("ServletContext destroyed");
|
||||
}
|
||||
|
||||
};
|
||||
}
|
||||
|
||||
public static void main(String[] args) throws Exception {
|
||||
SpringApplication.run(SampleTomcatApplication.class, args);
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
@@ -34,4 +34,5 @@ public class SampleController {
|
||||
public String helloWorld() {
|
||||
return this.helloWorldService.getHelloMessage();
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user