Spring Boot项目,运行不明中断。日志如下:

2018-11-03 11:03:43.358 INFO [Thread-2][AbstractApplicationContext.java:984]: Closing org.springframework.context.annotation.AnnotationConfigApplicationContext@7d70d1b1: startup date [Sat Nov 03 10:54:46 CST 2018]; root of context hierarchy

异常原因:

  启动脚本:java -jar lib/cdc-×××-1.0.3-SNAPSHOT.jar >>cdc-×××.log  2>&1 &

  这样启动的进程,虽然不会占用控制台,但还是会随着远程终端的中断而中断;

解决方法:

  用nohup 命令来启动服务:

  nohup java -jar lib/cdc-×××-1.0.3-SNAPSHOT.jar >>cdc-×××.log  2>&1 &

补充说明:

nohup命令 可以将程序以忽略挂起信号的方式运行起来,被运行的程序的输出信息将不会显示到终端。

root of context hierarchy的更多相关文章

  1. LifecycleProcessor not initialized - call 'refresh' before invoking lifecycle methods via the context: Root WebApplicationContext: startup date [Sun Jan 13 17:59:19 CST 2019]; root of context hierarch

    在运行项目时出现了:LifecycleProcessor not initialized - call 'refresh' before invoking lifecycle methods via ...

  2. java.lang.IllegalStateException: Cannot initialize context because there is already a root application context present

    @Controller@ComponentScan@Configuration@EnableScheduling@EnableAutoConfiguration(exclude={DataSource ...

  3. root of factory hierarchy

    项目编译错误! project---->clean

  4. 能源项目xml文件标签释义--<context:component-scan>

    <context:component-scan base-package="com.xindatai.ibs" use-default-filters="false ...

  5. Unable to start web server; nested exception is org.springframework.context.ApplicationContextException: Unable to start ServletWebServerApplicationContext due to missing ServletWebServerFactory bean.

    SpringBoot启动时的异常信息如下: "C:\Program Files\Java\jdk1.8.0_161\bin\java" ......... com.fangxing ...

  6. spring注解注入:<context:component-scan>详解

    spring从2.5版本开始支持注解注入,注解注入可以省去很多的xml配置工作.由于注解是写入java代码中的,所以注解注入会失去一定的灵活性,我们要根据需要来选择是否启用注解注入. 我们首先看一个注 ...

  7. eclipse的jdk版本和spring冲突问题WARN XmlWebApplicationContext:1060 - Exception thrown from LifecycleProcessor on context close

    项目环境: jdk1.8 tomcat7 问题:eclipse启动tomcat后控制台报如下错误: WARN XmlWebApplicationContext:1060 - Exception thr ...

  8. 【spring mvc】application context中【bean】的生命周期

    生命周期过程 主要分为四部分: 一.实例化 1. 当调用者通过 getBean( name )向 容器寻找Bean 时,如果容器注册了org.springframework.beans.factory ...

  9. LifecycleProcessor not initialized - call 'refresh' before invoking lifecycle methods via the context: --异常记录

    升级了JDK之后,启动应用,直接抛出此异常.网上搜罗半天,没有正确的解决方案. 然后想到了是“升级了JDK”,重新检查所有JDK相关的配置的地方,在Debug Configurations里找到启动时 ...

随机推荐

  1. pandas简介

  2. MySQL锁表解决方法

    https://blog.csdn.net/a5582ddff/article/details/79566678 MySQL锁表解决方法 一.我的处理过程 1.查进程,主要是查找被锁表的那个进程的ID ...

  3. tcp关闭连接:挥手讨论

    讨论焦点: 如果client发送FIN后,服务器端未返回完成的数据(缓存区中)还执行返回吗? 参考文档:https://download.csdn.net/download/u013547552/10 ...

  4. 什么是微服务 Martin Fowler的microservices

    https://martinfowler.com/articles/microservices.html https://martinfowler.com/microservices/ 微服务,最早由 ...

  5. 深入理解Kubernetes资源限制:内存

    写在前面 当我开始大范围使用Kubernetes的时候,我开始考虑一个我做实验时没有遇到的问题:当集群里的节点没有足够资源的时候,Pod会卡在Pending状态.你是没有办法给节点增加CPU或者内存的 ...

  6. less运算

    less里面是可以有运算的,任何数字,颜色或者变量都可以参与与暗算,运算应该被包裹在括号中.   @test_width:300px; .box_width{ width: (@test_width ...

  7. synchronized 和 Lock 有什么区别?(未完成)

    synchronized 和 Lock 有什么区别?(未完成)

  8. Pytest编写测试函数

    Pytest编写测试函数 一个规范的测试方法一定带有断言,在使用pytest时,可以直接使用Python自带的assert关键字 Pytest允许在assert关键字添加任意表达式,表达式的值通过bo ...

  9. vscode远程修改文件('file': A system error occured )

    The command you want is :e (short for :edit). If you use :edit! it will discard local changes and re ...

  10. LevelDB的源码阅读(一)

    源码下载 git clone https://github.com/google/leveldb.git 项目结构 db/, 数据库逻辑 doc/, MD文档 helpers/, LevelDB内存版 ...