fixed env variables not working 10/108210/1
authorMichael Dürre <michael.duerre@highstreet-technologies.com>
Mon, 25 May 2020 17:18:20 +0000 (19:18 +0200)
committerMichael Dürre <michael.duerre@highstreet-technologies.com>
Mon, 25 May 2020 17:18:37 +0000 (19:18 +0200)
fixed regex for env property values

Issue-ID: SDNC-1196
Signed-off-by: Michael Dürre <michael.duerre@highstreet-technologies.com>
Change-Id: Ia8a96110f000438bec84d235dde484d313f45a8e

sdnr/wt/common/src/main/java/org/onap/ccsdk/features/sdnr/wt/common/configuration/subtypes/Section.java

index b6d277f..39c00da 100644 (file)
@@ -98,7 +98,7 @@ public class Section {
                if (value != null && value.contains("${")) {
                        
                        LOG.debug("try to find env var(s) for {}",value);
-                       final String regex = "(\\$\\{[A-Z]+\\})";
+                       final String regex = "(\\$\\{[A-Z0-9_-]+\\})";
                        final Pattern pattern = Pattern.compile(regex);
                        final Matcher matcher = pattern.matcher(value);
                        String tmp=new String(value);