IDEA 新建spring Boot 项目新建后启动失败, 提示Unregistering JMX-exposed beans on shutdown
博客专区 > 诺岚 的博客 > 博客详情
IDEA 新建spring Boot 项目新建后启动失败, 提示Unregistering JMX-exposed beans on shutdown
诺岚 发表于2个月前
IDEA 新建spring Boot 项目新建后启动失败, 提示Unregistering JMX-exposed beans on shutdown
  • 发表于 2个月前
  • 阅读 23
  • 收藏 0
  • 点赞 0
  • 评论 0

腾讯云 十分钟定制你的第一个小程序>>>   

建项目的步骤:

 

新建好项目后运行,出错:

   _            __ _ _
 /\\ / ___'_ __ _ _(_)_ __  __ _ \ \ \ \
( ( )\___ | '_ | '_| | '_ \/ _` | \ \ \ \
 \\/  ___)| |_)| | | | | || (_| |  ) ) ) )
  '  |____| .__|_| |_|_| |_\__, | / / / /
 =========|_|==============|___/=/_/_/_/
 :: Spring Boot ::        (v1.5.6.RELEASE)

2017-09-05 11:25:45.397  INFO 10244 --- [           main] com.example.demo.DemoApplication         : Starting DemoApplication on admin-PC with PID 10244 (D:\usr\demo\target\classes started by admin in D:\usr\demo)
2017-09-05 11:25:45.399  INFO 10244 --- [           main] com.example.demo.DemoApplication         : No active profile set, falling back to default profiles: default
2017-09-05 11:25:45.428  INFO 10244 --- [           main] s.c.a.AnnotationConfigApplicationContext : Refreshing org.springframework.context.annotation.AnnotationConfigApplicationContext@120d6fe6: startup date [Tue Sep 05 11:25:45 CST 2017]; root of context hierarchy
2017-09-05 11:25:45.748  WARN 10244 --- [           main] o.h.v.m.ParameterMessageInterpolator     : HV000184: ParameterMessageInterpolator has been chosen, EL interpolation will not be supported
2017-09-05 11:25:45.825  WARN 10244 --- [           main] o.h.v.m.ParameterMessageInterpolator     : HV000184: ParameterMessageInterpolator has been chosen, EL interpolation will not be supported
2017-09-05 11:25:45.999  INFO 10244 --- [           main] o.s.j.e.a.AnnotationMBeanExporter        : Registering beans for JMX exposure on startup
2017-09-05 11:25:46.008  INFO 10244 --- [           main] com.example.demo.DemoApplication         : Started DemoApplication in 0.759 seconds (JVM running for 1.246)
2017-09-05 11:25:46.009  INFO 10244 --- [       Thread-4] s.c.a.AnnotationConfigApplicationContext : Closing org.springframework.context.annotation.AnnotationConfigApplicationContext@120d6fe6: startup date [Tue Sep 05 11:25:45 CST 2017]; root of context hierarchy
2017-09-05 11:25:46.010  INFO 10244 --- [       Thread-4] o.s.j.e.a.AnnotationMBeanExporter        : Unregistering JMX-exposed beans on shutdown

Process finished with exit code 0

解决方法:

 

需要添加tomcat插件, 还不能有<scope>provided</scope> 添加依赖:
<dependency>
  <groupId>org.springframework.boot</groupId>
  <artifactId>spring-boot-starter-tomcat</artifactId>
</dependency>

然后刷新项目。再次运行:

共有 人打赏支持
粉丝 0
博文 57
码字总数 91768
×
诺岚
如果觉得我的文章对您有用,请随意打赏。您的支持将鼓励我继续创作!
* 金额(元)
¥1 ¥5 ¥10 ¥20 其他金额
打赏人
留言
* 支付类型
微信扫码支付
打赏金额:
已支付成功
打赏金额: