diff options
author | Michael Mokry <michael.mokry@att.com> | 2018-11-02 15:08:38 -0500 |
---|---|---|
committer | Michael Mokry <michael.mokry@att.com> | 2018-11-06 21:14:23 +0000 |
commit | a85a1546bb718a7643b4dc92622cedb827082f02 (patch) | |
tree | db78e860588a7b0b0dc8d9714ffbf69d1bbfde55 /ONAP-REST/src/main/java/org | |
parent | 677d872505a8b74a175023ff199b123ff2147dc8 (diff) |
Removed Objective From keyword check in parser
Modified the Model parser code to allow "objective" as a field name in
yaml.
Change-Id: Ia3667ebc84a0bbdbbb3723bdcf0237a8f35313ee
Issue-ID: POLICY-1244
Signed-off-by: Michael Mokry <michael.mokry@att.com>
(cherry picked from commit 51842453b199a7c3a6785f4ab047612d50eab3b9)
Diffstat (limited to 'ONAP-REST/src/main/java/org')
-rw-r--r-- | ONAP-REST/src/main/java/org/onap/policy/rest/util/MSModelUtils.java | 4 |
1 files changed, 1 insertions, 3 deletions
diff --git a/ONAP-REST/src/main/java/org/onap/policy/rest/util/MSModelUtils.java b/ONAP-REST/src/main/java/org/onap/policy/rest/util/MSModelUtils.java index 54713ceef..f145f4db1 100644 --- a/ONAP-REST/src/main/java/org/onap/policy/rest/util/MSModelUtils.java +++ b/ONAP-REST/src/main/java/org/onap/policy/rest/util/MSModelUtils.java @@ -1214,9 +1214,7 @@ public class MSModelUtils { hm = new LinkedHashMap<>(); String keyStr = key.substring(key.lastIndexOf('.') + 1); String valueStr = map.get(key); - if (key.contains(".objective.")) { - throw new ParserException("Attribute objective is a key word. Please use a different name"); - } + if (("type").equals(keyStr)) { if (!key.contains("entry_schema")) { hm.put(keyStr, valueStr); |