如何降低 Spring Cloud Config 的属性加载器的优先级?我需要能够通过命令行参数覆盖属性,但由于 Cloud Config 属性加载器的优先级最高,目前这是不可能的。
例如,如果 MyApp.jar 从 Cloud Config 中的 MyApp.yml 中提取变量“foo=bar”,我希望能够使用以下命令:
java -jar MyApp.jar --foo=baz
如何降低 Spring Cloud Config 的属性加载器的优先级?我需要能够通过命令行参数覆盖属性,但由于 Cloud Config 属性加载器的优先级最高,目前这是不可能的。
例如,如果 MyApp.jar 从 Cloud Config 中的 MyApp.yml 中提取变量“foo=bar”,我希望能够使用以下命令:
java -jar MyApp.jar --foo=baz