我正在开发一个spring boot应用程序,希望有一个类似于基本配置文件继承的东西。
我想知道如何将以下内容存档:
if profile A.hello is active
then profile A.world needs to be activated as well有没有办法做到这一点?
发布于 2018-04-11 14:14:56
您可以通过自动装配环境变量来获取活动的配置文件
@Autowired
Environment environment;
...
environment.getActiveProfiles()https://stackoverflow.com/questions/49761959
复制相似问题