Using STS, if I import the project "Rest Service" Getting Started using the latest Spring boot and select "Run As Spring Boot App" , it will start and then shut down immediately.
Looking at the debug logs, Spring, for some reason, the project solution is not a web application, but I have no idea why.
If I switch from Spring Boot 1.1.1.RELEASE to 1.0.1.RELEASE , the project will work as expected and the default Tomcat built-in server will be found.
Can't I find anything in the release notes for 1.1.1 that says there is a configuration change or something else?
UPDATE: steps to play and exit the log
I am running STS 3.6.0.M1 and Spring 4.0.5 and Spring Boot 1.1.1. I can easily reproduce this by following these steps:
- Import REST Service Application Getting Started.
- Select Run As Spring Boot Project
This is the result:
:: Spring Boot :: (v1.1.1.RELEASE) 2014-06-14 11:08:34.226 INFO 47728 --- [ main] hello.Application : Starting Application on localhost with PID 47728 (/Users/pdrummond/src/sts/gs-rest-service-complete/target/classes started by pdrummond in /Users/pdrummond/src/sts/gs-rest-service-complete) 2014-06-14 11:08:34.257 INFO 47728 --- [ main] scaAnnotationConfigApplicationContext : Refreshing org.springframework.context.annotation.AnnotationConfigApplicationContext@802b249: startup date [Sat Jun 14 11:08:34 BST 2014]; root of context hierarchy 2014-06-14 11:08:34.680 INFO 47728 --- [ main] osjeaAnnotationMBeanExporter : Registering beans for JMX exposure on startup 2014-06-14 11:08:34.908 INFO 47728 --- [ main] hello.Application : Started Application in 0.917 seconds (JVM running for 1.351) 2014-06-14 11:08:36.397 INFO 47728 --- [ Thread-3] scaAnnotationConfigApplicationContext : Closing org.springframework.context.annotation.AnnotationConfigApplicationContext@802b249: startup date [Sat Jun 14 11:08:34 BST 2014]; root of context hierarchy 2014-06-14 11:08:36.398 INFO 47728 --- [ Thread-3] osjeaAnnotationMBeanExporter : Unregistering JMX-exposed beans on shutdown
If I edit pom and change spring-boot-starter-parent to 1.0.1.RELEASE , it will boot as expected.
UPDATE 2: Added output from the --debug command
:: Spring Boot :: (v1.1.1.RELEASE) 2014-06-14 19:29:03.814 INFO 986 --- [ main] hello.Application : Starting Application on localhost with PID 986 (/Users/pdrummond/src/sts/gs-rest-service-complete/target/classes started by pdrummond in /Users/pdrummond/src/sts/gs-rest-service-complete) 2014-06-14 19:29:03.816 DEBUG 986 --- [ main] osboot.SpringApplication : Loading source class hello.Application 2014-06-14 19:29:03.838 INFO 986 --- [ main] scaAnnotationConfigApplicationContext : Refreshing org.springframework.context.annotation.AnnotationConfigApplicationContext@c163956: startup date [Sat Jun 14 19:29:03 BST 2014]; root of context hierarchy 2014-06-14 19:29:04.177 INFO 986 --- [ main] osjeaAnnotationMBeanExporter : Registering beans for JMX exposure on startup 2014-06-14 19:29:04.346 DEBUG 986 --- [ main] utoConfigurationReportLoggingInitializer : ========================= AUTO-CONFIGURATION REPORT ========================= Positive matches: ----------------- PropertyPlaceholderAutoConfiguration
spring spring-boot
Paul Drummond Jun 13 '14 at 9:46 a.m. 2014-06-13 21:46
source share