• 请不要在回答技术问题时复制粘贴 AI 生成的内容
luxinfl
V2EX  ›  程序员

发现 springboot 在 Linux 启动时,配置文件格式错误的日志打印无解啊

  •  
  •   luxinfl · Jun 15, 2021 · 1604 views
    This topic created in 1845 days ago, the information mentioned may be changed or developed.
    了解到有个 DeferredLog,这玩意在 spring 上下文完全初始化之前会缓存日志,如果此时配置文件格式错误,抛的异常不会打到指定文件。看样子只能用 shell 脚本解决这个日志打印问题了。大佬们有什么高招麽??
    1 replies    2021-06-15 15:17:40 +08:00
    guxingke
        1
    guxingke  
       Jun 15, 2021
    shell 不也挺好。。。

    xx.sh 1>stdout.log 2>stderr.log &
    About   ·   Help   ·   Advertise   ·   Blog   ·   API   ·   FAQ   ·   Solana   ·   3031 Online   Highest 6679   ·     Select Language
    创意工作者们的社区
    World is powered by solitude
    VERSION: 3.9.8.5 · 41ms · UTC 08:16 · PVG 16:16 · LAX 01:16 · JFK 04:16
    ♥ Do have faith in what you're doing.