diff options
author | aribeiro <anderson.ribeiro@est.tech> | 2020-09-15 08:20:39 +0100 |
---|---|---|
committer | Anderson Ribeiro <anderson.ribeiro@est.tech> | 2020-09-29 06:33:44 +0000 |
commit | 0fa53516c409ac136f654475c1e41c77cad9cf09 (patch) | |
tree | ed7fc3e956fe8a1a12a0726fa81c673f4eb72951 /common-app-api/src/main/java | |
parent | f2d671f77248730e10d925ae5f8c02abc09de6e1 (diff) |
Allow hot reloading of specific config properties
getGlobalCsarImports and getDefaultImports entries are now
not static which will allow to get new values if the config
file change during runtime.
Issue-ID: SDC-3303
Signed-off-by: aribeiro <anderson.ribeiro@est.tech>
Change-Id: I870c13aec5d386aa3c87d6a335b5fb5948073954
Diffstat (limited to 'common-app-api/src/main/java')
-rw-r--r-- | common-app-api/src/main/java/org/openecomp/sdc/be/config/Configuration.java | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/common-app-api/src/main/java/org/openecomp/sdc/be/config/Configuration.java b/common-app-api/src/main/java/org/openecomp/sdc/be/config/Configuration.java index 2841dfd123..4ec7a16a5c 100644 --- a/common-app-api/src/main/java/org/openecomp/sdc/be/config/Configuration.java +++ b/common-app-api/src/main/java/org/openecomp/sdc/be/config/Configuration.java @@ -23,10 +23,12 @@ package org.openecomp.sdc.be.config; import static java.lang.String.format; import static java.util.Collections.emptyMap; +import java.util.Collections; import java.util.Date; import java.util.List; import java.util.Map; import java.util.Set; +import org.apache.commons.collections.CollectionUtils; import org.apache.commons.collections.map.CaseInsensitiveMap; import org.openecomp.sdc.common.api.BasicConfiguration; @@ -1598,6 +1600,9 @@ public class Configuration extends BasicConfiguration { } public List<String> getGlobalCsarImports() { + if (CollectionUtils.isEmpty(globalCsarImports)) { + return Collections.emptyList(); + } return globalCsarImports; } |