SpringBoot启动失败报 “exit code 1“

报错信息如下

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

2022-03-26 23:10:01 [INFO ] com.sx.srb.core.ServiceCoreApplication Starting ServiceCoreApplication on DESKTOP-IVFVHS1 with PID 20688 (D:\file\project\srb\srb\service-core\target\classes started by 宋亚辉 in D:\file\project\srb\srb)
2022-03-26 23:10:01 [INFO ] com.sx.srb.core.ServiceCoreApplication The following profiles are active: dev
Logging initialized using 'class org.apache.ibatis.logging.stdout.StdOutImpl' adapter.
Registered plugin: 'com.baomidou.mybatisplus.extension.plugins.MybatisPlusInterceptor@57046e0c'
Parsed mapper file: 'file [D:\file\project\srb\srb\service-core\target\classes\com\sx\srb\core\mapper\xml\BorrowInfoMapper.xml]'
Parsed mapper file: 'file [D:\file\project\srb\srb\service-core\target\classes\com\sx\srb\core\mapper\xml\BorrowerAttachMapper.xml]'
Parsed mapper file: 'file [D:\file\project\srb\srb\service-core\target\classes\com\sx\srb\core\mapper\xml\BorrowerMapper.xml]'
Parsed mapper file: 'file [D:\file\project\srb\srb\service-core\target\classes\com\sx\srb\core\mapper\xml\DictMapper.xml]'
Parsed mapper file: 'file [D:\file\project\srb\srb\service-core\target\classes\com\sx\srb\core\mapper\xml\IntegralGradeMapper.xml]'
Parsed mapper file: 'file [D:\file\project\srb\srb\service-core\target\classes\com\sx\srb\core\mapper\xml\LendItemMapper.xml]'
Parsed mapper file: 'file [D:\file\project\srb\srb\service-core\target\classes\com\sx\srb\core\mapper\xml\LendItemReturnMapper.xml]'
Parsed mapper file: 'file [D:\file\project\srb\srb\service-core\target\classes\com\sx\srb\core\mapper\xml\LendMapper.xml]'
Parsed mapper file: 'file [D:\file\project\srb\srb\service-core\target\classes\com\sx\srb\core\mapper\xml\LendReturnMapper.xml]'
Parsed mapper file: 'file [D:\file\project\srb\srb\service-core\target\classes\com\sx\srb\core\mapper\xml\TransFlowMapper.xml]'
Parsed mapper file: 'file [D:\file\project\srb\srb\service-core\target\classes\com\sx\srb\core\mapper\xml\UserAccountMapper.xml]'
Parsed mapper file: 'file [D:\file\project\srb\srb\service-core\target\classes\com\sx\srb\core\mapper\xml\UserBindMapper.xml]'
Parsed mapper file: 'file [D:\file\project\srb\srb\service-core\target\classes\com\sx\srb\core\mapper\xml\UserInfoMapper.xml]'
Parsed mapper file: 'file [D:\file\project\srb\srb\service-core\target\classes\com\sx\srb\core\mapper\xml\UserIntegralMapper.xml]'
Parsed mapper file: 'file [D:\file\project\srb\srb\service-core\target\classes\com\sx\srb\core\mapper\xml\UserLoginRecordMapper.xml]'
 _ _   |_  _ _|_. ___ _ |    _ 
| | |\/|_)(_| | |_\  |_)||_|_\ 
     /               |         
                        3.4.1 

Process finished with exit code 1

        由于最下面报了coed 1,很明显是进程直接异常关闭了。问题是如何打印出异常信息,个人用笨招,即用单元测试启动以此打印异常到控制台;

        异常信息的内容基本上就是IoC启动失败,启动失败的原因我这里都是该加的依赖未添加

        如果最下面报了coed 0,则是进程正常关闭。引起的原因我这里基本上是配置问题,比如端口被占用之类的资源上的问题

你可能感兴趣的:(#,Spring5.x,后端问题收录,java)