springboot 启动问题解决方法

问题:初始搭建springboot maven项目没有引入web 启动报错

Connected to the target VM, address: '127.0.0.1:58926', transport: 'socket'

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

2019-02-20 19:46:56.895  INFO 2502 --- [           main] com.moji.redis.RedisApiApplication       : Starting RedisApiApplication on Mirko.local with PID 2502 (/Users/li.liu/workspace2/redis-api/target/classes started by li.liu in /Users/li.liu/workspace2/redis-api)
2019-02-20 19:46:56.900  INFO 2502 --- [           main] com.moji.redis.RedisApiApplication       : The following profiles are active: dev
2019-02-20 19:46:57.656  INFO 2502 --- [           main] .s.d.r.c.RepositoryConfigurationDelegate : Multiple Spring Data modules found, entering strict repository configuration mode!
2019-02-20 19:46:57.659  INFO 2502 --- [           main] .s.d.r.c.RepositoryConfigurationDelegate : Bootstrapping Spring Data repositories in DEFAULT mode.
2019-02-20 19:46:57.691  INFO 2502 --- [           main] .s.d.r.c.RepositoryConfigurationDelegate : Finished Spring Data repository scanning in 15ms. Found 0 repository interfaces.
2019-02-20 19:46:58.519  INFO 2502 --- [           main] com.moji.redis.RedisApiApplication       : Started RedisApiApplication in 2.28 seconds (JVM running for 3.741)
Disconnected from the target VM, address: '127.0.0.1:58926', transport: 'socket'

Process finished with exit code 0

解决办法:

pom 引入依赖

<dependency>
    <groupId>org.springframework.boot</groupId>
    <artifactId>spring-boot-starter-web</artifactId>
</dependency>
  • 2
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 2
    评论

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论 2
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值