summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorsebdet <sebastien.determe@intl.att.com>2020-04-28 16:01:35 +0200
committersebdet <sebastien.determe@intl.att.com>2020-04-28 16:01:35 +0200
commit975dccc51b43b5a4019c45f448e63a110e3bd603 (patch)
treeff709422661494e215f563e877daf3dca5d2de50 /src
parent5523a23a5d8a66f690fc2dec7975cb8bfb8db975 (diff)
Fix VNF entityId in policies
Fix the VNF entity IDs value in json schema for each policies (in UI) Issue-ID: CLAMP-843 Signed-off-by: sebdet <sebastien.determe@intl.att.com> Change-Id: I9515b01422acdfc0ec36f10cc70994145e561d7f
Diffstat (limited to 'src')
-rw-r--r--src/main/java/org/onap/clamp/policy/operational/OperationalPolicyRepresentationBuilder.java2
-rw-r--r--src/test/resources/tosca/new-converter/tosca_apex_with_metadata.json2
-rw-r--r--src/test/resources/tosca/operational-policy-cds-payload-with-list.json2
-rw-r--r--src/test/resources/tosca/operational-policy-json-schema.json2
4 files changed, 4 insertions, 4 deletions
diff --git a/src/main/java/org/onap/clamp/policy/operational/OperationalPolicyRepresentationBuilder.java b/src/main/java/org/onap/clamp/policy/operational/OperationalPolicyRepresentationBuilder.java
index 5f6cb31b..ee403065 100644
--- a/src/main/java/org/onap/clamp/policy/operational/OperationalPolicyRepresentationBuilder.java
+++ b/src/main/java/org/onap/clamp/policy/operational/OperationalPolicyRepresentationBuilder.java
@@ -130,7 +130,7 @@ public class OperationalPolicyRepresentationBuilder {
properties.add(TYPE, createSchemaProperty("Type", STRING, "VNF", "True", null));
}
properties.add("resourceID", createSchemaProperty("Resource ID", STRING,
- modelVnfs.get(entry.getKey()).getAsJsonObject().get("name").getAsString(), "True", null));
+ modelVnfs.get(entry.getKey()).getAsJsonObject().get("invariantUUID").getAsString(), "True", null));
vnfOneOfSchema.add(PROPERTIES, properties);
vnfSchemaArray.add(vnfOneOfSchema);
diff --git a/src/test/resources/tosca/new-converter/tosca_apex_with_metadata.json b/src/test/resources/tosca/new-converter/tosca_apex_with_metadata.json
index e03e48fc..f6713aff 100644
--- a/src/test/resources/tosca/new-converter/tosca_apex_with_metadata.json
+++ b/src/test/resources/tosca/new-converter/tosca_apex_with_metadata.json
@@ -267,7 +267,7 @@
"resourceID": {
"title": "Resource ID",
"type": "string",
- "default": "vLoadBalancerMS",
+ "default": "1a31b9f2-e50d-43b7-89b3-a040250cf506",
"readOnly": "True"
}
}
diff --git a/src/test/resources/tosca/operational-policy-cds-payload-with-list.json b/src/test/resources/tosca/operational-policy-cds-payload-with-list.json
index 190636c4..9a9308e3 100644
--- a/src/test/resources/tosca/operational-policy-cds-payload-with-list.json
+++ b/src/test/resources/tosca/operational-policy-cds-payload-with-list.json
@@ -386,7 +386,7 @@
"resourceID": {
"title": "Resource ID",
"type": "string",
- "default": "vLoadBalancerMS",
+ "default": "1a31b9f2-e50d-43b7-89b3-a040250cf506",
"readOnly": "True"
}
}
diff --git a/src/test/resources/tosca/operational-policy-json-schema.json b/src/test/resources/tosca/operational-policy-json-schema.json
index 32adce9b..e8363b46 100644
--- a/src/test/resources/tosca/operational-policy-json-schema.json
+++ b/src/test/resources/tosca/operational-policy-json-schema.json
@@ -744,7 +744,7 @@
"resourceID": {
"title": "Resource ID",
"type": "string",
- "default": "vLoadBalancerMS",
+ "default": "1a31b9f2-e50d-43b7-89b3-a040250cf506",
"readOnly": "True"
}
}