1
我已經從入門指南「構建REST風格的Web服務」中下載了zip文件。Spring Boot Rest示例在我的系統上不起作用
但是我無法在我的系統上構建(mvn包)。 而行家試圖運行HelloControllerTest
Negative matches:
-----------------
ActiveMQAutoConfiguration did not match
- required @ConditionalOnClass classes not found: javax.jms.ConnectionFactory,org.apache.activemq.ActiveMQConnectionFactory (OnClassCondition)
AopAutoConfiguration did not match
- required @ConditionalOnClass classes not found: org.aspectj.lang.annotation.Aspect,org.aspectj.lang.reflect.Advice (OnClassCondition)
ArtemisAutoConfiguration did not match
- required @ConditionalOnClass classes not found: javax.jms.ConnectionFactory,org.apache.activemq.artemis.jms.client.ActiveMQConnectionFactory (OnClassCondition)
AuditAutoConfiguration#authenticationAuditListener did not match
- required @ConditionalOnClass classes not found: org.springframework.security.authentication.event.AbstractAuthenticationEvent (OnClassCondition)
AuditAutoConfiguration#authorizationAuditListener did not match
- required @ConditionalOnClass classes not found: org.springframework.security.access.event.AbstractAuthorizationEvent (OnClassCondition)
BatchAutoConfiguration did not match
- required @ConditionalOnClass classes not found: org.springframework.batch.core.launch.JobLauncher,org.springframework.jdbc.core.JdbcOperations (OnClassCondition)
CacheAutoConfiguration did not match
- @ConditionalOnClass classes found: org.springframework.cache.CacheManager (OnClassCondition)
- @ConditionalOnBean (types: org.springframework.cache.interceptor.CacheAspectSupport; SearchStrategy: all) found no beans (OnBeanCondition)
CacheAutoConfiguration.CacheManagerJpaDependencyConfiguration did not match
- required @ConditionalOnClass classes not found: org.springframework.orm.jpa.LocalContainerEntityManagerFactoryBean (OnClassCondition)
- Ancestor 'org.springframework.boot.autoconfigure.cache.CacheAutoConfiguration' did not match (ConditionEvaluationReport.AncestorsMatchedCondition)
CacheStatisticsAutoConfiguration did not match
- @ConditionalOnBean (types: org.springframework.cache.CacheManager; SearchStrategy: all) found no beans (OnBeanCondition)
CacheStatisticsAutoConfiguration.CaffeineCacheStatisticsProviderConfiguration did not match
- required @ConditionalOnClass classes not found: com.github.benmanes.caffeine.cache.Caffeine,org.springframework.cache.caffeine.CaffeineCacheManager (OnClassCondition)
- Ancestor 'org.springframework.boot.actuate.autoconfigure.CacheStatisticsAutoConfiguration' did not match (ConditionEvaluationReport.AncestorsMatchedCondition)
CacheStatisticsAutoConfiguration.ConcurrentMapCacheStatisticsConfiguration did not match
- @ConditionalOnClass classes found: org.springframework.cache.concurrent.ConcurrentMapCache (OnClassCondition)
- Ancestor 'org.springframework.boot.actuate.autoconfigure.CacheStatisticsAutoConfiguration' did not match (ConditionEvaluationReport.AncestorsMatchedCondition)
CacheStatisticsAutoConfiguration.EhCacheCacheStatisticsProviderConfiguration did not match
- required @ConditionalOnClass classes not found: org.springframework.cache.ehcache.EhCacheCache,net.sf.ehcache.Ehcache,net.sf.ehcache.statistics.StatisticsGateway (OnClassCondition)
- Ancestor 'org.springframework.boot.actuate.autoconfigure.CacheStatisticsAutoConfiguration' did not match (ConditionEvaluationReport.AncestorsMatchedCondition)
CacheStatisticsAutoConfiguration.GuavaCacheStatisticsConfiguration did not match
- required @ConditionalOnClass classes not found: com.google.common.cache.Cache,org.springframework.cache.guava.GuavaCache (OnClassCondition)
- Ancestor 'org.springframework.boot.actuate.autoconfigure.CacheStatisticsAutoConfiguration' did not match (ConditionEvaluationReport.AncestorsMatchedCondition)
CacheStatisticsAutoConfiguration.HazelcastCacheStatisticsConfiguration did not match
- required @ConditionalOnClass classes not found: com.hazelcast.core.IMap,com.hazelcast.spring.cache.HazelcastCache (OnClassCondition)
- Ancestor 'org.springframework.boot.actuate.autoconfigure.CacheStatisticsAutoConfiguration' did not match (ConditionEvaluationReport.AncestorsMatchedCondition)
CacheStatisticsAutoConfiguration.InfinispanCacheStatisticsProviderConfiguration did not match
- required @ConditionalOnClass classes not found: org.infinispan.spring.provider.SpringCache (OnClassCondition)
- Ancestor 'org.springframework.boot.actuate.autoconfigure.CacheStatisticsAutoConfiguration' did not match (ConditionEvaluationReport.AncestorsMatchedCondition)
CacheStatisticsAutoConfiguration.JCacheCacheStatisticsProviderConfiguration did not match
- required @ConditionalOnClass classes not found: javax.cache.Caching,org.springframework.cache.jcache.JCacheCache (OnClassCondition)
- Ancestor 'org.springframework.boot.actuate.autoconfigure.CacheStatisticsAutoConfiguration' did not match (ConditionEvaluationReport.AncestorsMatchedCondition)
CacheStatisticsAutoConfiguration.NoOpCacheStatisticsConfiguration did not match
- @ConditionalOnClass classes found: org.springframework.cache.support.NoOpCacheManager (OnClassCondition)
- Ancestor 'org.springframework.boot.actuate.autoconfigure.CacheStatisticsAutoConfiguration' did not match (ConditionEvaluationReport.AncestorsMatchedCondition)
CaffeineCacheConfiguration did not match
- required @ConditionalOnClass classes not found: com.github.benmanes.caffeine.cache.Caffeine,org.springframework.cache.caffeine.CaffeineCacheManager (OnClassCondition)
我刪除了所有的測試,並試圖運行應用程序(:運行mvn春季啓動),我收到以下錯誤消息。現在我只是得到以下回:
2016-09-02 12:13:00.959 INFO 14020 --- [ main] hello.Application : Starting Application on myHost with PID 14020 (C:\Users\myUser\Desktop\gs-spring-boot-master\comp lete\target\classes started by myUser in C:\Users\myUser\Desktop\gs-spring-boot-master\complete) 2016-09-02 12:13:00.964 INFO 14020 --- [ main] hello.Application : No active profile set, falling back to default profiles: default 2016-09-02 12:13:01.080 INFO 14020 --- [ main] s.c.a.AnnotationConfigApplicationContext : Refreshing org.spring[email protected]438b2516: star tup date [Fri Sep 02 12:13:01 CEST 2016]; root of context hierarchy 2016-09-02 12:13:03.423 INFO 14020 --- [ main] o.s.j.e.a.AnnotationMBeanExporter : Registering beans for JMX exposure on startup 2016-09-02 12:13:03.433 INFO 14020 --- [ main] o.s.c.support.DefaultLifecycleProcessor : Starting beans in phase 0 Let's inspect the beans provided by Spring Boot: 2016-09-02 12:13:03.563 INFO 14020 --- [ main] hello.Application : Started Application in 3.219 seconds (JVM running for 8.376) [INFO]
------------------------------------------------------------------------ [INFO] BUILD SUCCESS [INFO]
------------------------------------------------------------------------ [INFO] Total time: 7.018 s [INFO] Finished at: 2016-09-02T12:13:03+02:00 [INFO] Final Memory: 36M/308M [INFO]
------------------------------------------------------------------------ 2016-09-02 12:13:03.888 INFO 14020 --- [ Thread-1] s.c.a.AnnotationConfigApplicationContext : Closing org.spring[email protected]438b2516: startup date [Fri Sep 02 12:13:01 CEST 2016]; root of context hierarchy 2016-09-02 12:13:03.892 INFO 14020 --- [ Thread-1] o.s.c.support.DefaultLifecycleProcessor : Stopping beans in phase 0 2016-09-02 12:13:03.895 INFO 14020 --- [ Thread-1] o.s.j.e.a.AnnotationMBeanExporter : Unregistering JMX-exposed beans on shutdown
我會期待ConfigEmbeddedWebApplicationContext將被使用。但是使用AnnotationConfigApplicationContext。沒有tomcat的開始!
我使用: 的Maven 3.3.9 jdk的1.8 Windows 7的
任何幫助將受到歡迎。 謝謝Jörg
我正在使用彈簧啓動1.4.0 –
這些不是錯誤,這是Spring Boot的自動配置報告,它在調試中運行時顯示更多。我不知道你刪除了什麼,但該指南適用於我。 –
同樣在這裏。我嘗試使用Spring的教程之一。我安裝了Spring STS來日食,我得到了相同的輸出。線程結束時退出。 – user2656851