Spring boot Spring Boot Rest示例在我的系统上不起作用

Spring boot Spring Boot Rest示例在我的系统上不起作用,spring-boot,Spring Boot,我已经从入门指南“构建RESTful Web服务”下载了zip文件 但是,我无法在我的系统上构建(mvn包)。 当maven尝试运行HelloControllerTest时,我收到以下错误消息 Negative matches: ----------------- ActiveMQAutoConfiguration did not match - required @ConditionalOnClass classes not found: javax.jms.Connect

我已经从入门指南“构建RESTful Web服务”下载了zip文件

但是,我无法在我的系统上构建(mvn包)。 当maven尝试运行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 spring boot:run)。现在,我刚刚得到以下信息:

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.springframework.context.annotation.AnnotationConfigApplicationContext@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.springframework.context.annotation.AnnotationConfigApplicationContext@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。而是使用注释ConfigApplicationContext。没有tomcat启动

我正在使用: Maven 3.3.9 JDK1.8 视窗7

欢迎任何帮助。
谢谢,Jörg找到了解决方案。我在本地Maven缓存中发现一个损坏的tomcat.embed-core-8.5.4依赖项。我删除了它并再次检索了依赖项。现在它可以工作了。

我正在使用spring boot 1.4.0这些都不是错误,这是spring boot在debug more中运行时显示的自动配置报告。我不知道你删除了什么,但那个指南对我有用。这里也一样。我尝试使用的Spring教程之一。我在eclipse上安装了SpringSTS,得到了相同的输出。线程在末尾退出。