Skip to content

有没有什么解决办法,既能看到Apollo启动日志,又能在启动时加载配置在Apollo的Logback的相关参数 #3671

@whitefeather2018

Description

@whitefeather2018

使用的Apollo版本 1.4.0
问题描述:
1.配置apollo.bootstrap.eagerLoad.enabled=true
2.在logback-spring.xml中使用<springProperty.../>读取配置项,该配置项配置在Apollo管理端
效果:该logback文件可以获取Apollo管理端的配置进行初始化。
带来的问题:由于日志系统初始化时机早于Apollo加载时机,导致Apollo的启动日志无法输出。

如果apollo.bootstrap.eagerLoad.enabled配置成fasle,可以看到Apollo启动日志,但配置在Apollo中的ogback相关的配置参数无法加载。

咨询:有没有什么解决办法,既能看到Apollo启动日志,又能在启动时加载配置在Apollo的Logback的相关参数。

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions