【问题标题】:How are some variables injected to application.yml in spring boot when it is startedspring boot 启动时如何将一些变量注入到 application.yml 中
【发布时间】:2016-12-29 10:27:12
【问题描述】:

我有一个 spring boot-1.4.1.RELEASE 应用程序
另一个应用程序依赖于我的应用程序,它的变量比我的 application.yml 的变量多,它希望在启动时将此变量注入我的 application.yml。
它是怎么做的?
有可能吗?

【问题讨论】:

标签: java spring-boot


【解决方案1】:

您可以为此目的使用 Spring Cloud Config Server。这是一个很好的教程:

https://cloud.spring.io/spring-cloud-config/spring-cloud-config.html

【讨论】:

    猜你喜欢
    • 2014-09-15
    • 2020-03-01
    • 2019-05-23
    • 2014-12-22
    • 2022-01-09
    • 2020-06-09
    • 2018-01-04
    • 2019-05-09
    • 1970-01-01
    相关资源
    最近更新 更多