summaryrefslogtreecommitdiffstats
path: root/mso-api-handlers/mso-api-handler-infra/src/test/resources/MsoRequestTest/SuccessfulValidation
diff options
context:
space:
mode:
authorMichael Pruss <michael.pruss@bell.ca>2021-05-31 18:28:08 -0400
committerJozsef Csongvai <jozsef.csongvai@bell.ca>2021-07-30 12:24:31 -0400
commited5c51313c1bd3745a554888c969e840341599b0 (patch)
tree27b6ed17d52f0d8b14428c98b0886d60a70670bc /mso-api-handlers/mso-api-handler-infra/src/test/resources/MsoRequestTest/SuccessfulValidation
parent1be8408f26d3f20cf2ffb923a956b7ba6dfbd994 (diff)
Support instantiation of same model vnfs/vf-modules
When instantiating a service with multiple vnfs and/or vfmodules SO would differentiate using ModelCustomizationId. This would cause issues when creating multiple instances of same model resource, and each lookup would return the same object. Instead of using ModelCustomizationId, this patch enables SO to use instanceName parameter to differentiate the resources. Validation was added to ensure that instanceNames are provided if there are multiple resources of the same model. If there are no duplicate resources and instanceName is not set, SO will default to previous logic using ModelCustomizationId. In order to properly associate vfmodules with their parent vnfs, the Resource class was augmented with a parent reference which maintains the relationship in further processing. Id generation logic was corrected to ensure that multiple resources of the same model are assigned unique instance ids and references to parent instanceId. Issue-ID: SO-3677 Change-Id: If39a0138f501177e12262f8e911137012e287fca Signed-off-by: Michael Pruss <michael.pruss@bell.ca>
Diffstat (limited to 'mso-api-handlers/mso-api-handler-infra/src/test/resources/MsoRequestTest/SuccessfulValidation')
-rw-r--r--mso-api-handlers/mso-api-handler-infra/src/test/resources/MsoRequestTest/SuccessfulValidation/ServiceAssign.json12
1 files changed, 8 insertions, 4 deletions
diff --git a/mso-api-handlers/mso-api-handler-infra/src/test/resources/MsoRequestTest/SuccessfulValidation/ServiceAssign.json b/mso-api-handlers/mso-api-handler-infra/src/test/resources/MsoRequestTest/SuccessfulValidation/ServiceAssign.json
index bc6f8fc610..d8bfcc2d5b 100644
--- a/mso-api-handlers/mso-api-handler-infra/src/test/resources/MsoRequestTest/SuccessfulValidation/ServiceAssign.json
+++ b/mso-api-handlers/mso-api-handler-infra/src/test/resources/MsoRequestTest/SuccessfulValidation/ServiceAssign.json
@@ -72,7 +72,8 @@
"modelName": "201673MowBvL._base__BV..module-0",
"modelVersionId": "3c40d244-808e-42ca-b09a-256d83d19d0a",
"modelCustomizationId": "a25e8e8c-58b8-4eec-810c-97dcc1f5cb7f"
- },
+ },
+ "instanceName": "vfModule1",
"instanceParams": [
{
"vmx_int_net_len": "24",
@@ -86,7 +87,8 @@
"modelVersionId": "3c40d244-808e-42ca-b09a-256d83d19d0a",
"modelCustomizationId": "72d9d1cd-f46d-447a-abdb-451d6fb05fa8",
"modelType": "vfModule"
- },
+ },
+ "instanceName": "vfModule2",
"instanceParams": [
{
"availability_zone_0": "mtpocdv-kvm-az01",
@@ -99,7 +101,8 @@
"modelName": "201673MowBvL._vRE_BV..module-1",
"modelVersionId": "3c40d244-808e-42ca-b09a-256d83d19d0a",
"modelCustomizationId": "72d9d1cd-f46d-447a-abdb-451d6fb05fa8"
- },
+ },
+ "instanceName": "vfModule3",
"instanceParams": [
{
"availability_zone_0": "mtpocdv-kvm-az01",
@@ -112,7 +115,8 @@
"modelName": "201673MowBvL._vPFE_BV..module-2",
"modelVersionId": "3c40d244-808e-42ca-b09a-256d83d19d0a",
"modelCustomizationId": "da4d4327-fb7d-4311-ac7a-be7ba60cf969"
- },
+ },
+ "instanceName": "vfModule4",
"instanceParams": [
{
"availability_zone_0": "mtpocdv-kvm-az01",