fix how we get cloud info in GR_API

added jpa repo for northbound request with a cloudowner

Change-Id: I3a2aeb3547f194bc404ed1bc08ba6d8560961a79
Issue-ID: SO-1283
Signed-off-by: Kalkere Ramesh, Sharan (sk720x) <sk720x@att.com>
diff --git a/bpmn/so-bpmn-tasks/src/test/resources/__files/Macro/CreateNetworkCollection.json b/bpmn/so-bpmn-tasks/src/test/resources/__files/Macro/CreateNetworkCollection.json
index 7b369ab..579075f 100644
--- a/bpmn/so-bpmn-tasks/src/test/resources/__files/Macro/CreateNetworkCollection.json
+++ b/bpmn/so-bpmn-tasks/src/test/resources/__files/Macro/CreateNetworkCollection.json
@@ -8,6 +8,7 @@
 			"modelVersion": "10"
 		},
 		"cloudConfiguration": {
+			"cloudOwner" : "my-custom-cloud-owner",
 			"lcpCloudRegionId": "mdt1",
 			"tenantId": "88a6ca3ee0394ade9403f075db23167e"
 		},
diff --git a/bpmn/so-bpmn-tasks/src/test/resources/__files/Macro/ServiceMacroActivateDeleteUnassign.json b/bpmn/so-bpmn-tasks/src/test/resources/__files/Macro/ServiceMacroActivateDeleteUnassign.json
index 771283c..2683802 100644
--- a/bpmn/so-bpmn-tasks/src/test/resources/__files/Macro/ServiceMacroActivateDeleteUnassign.json
+++ b/bpmn/so-bpmn-tasks/src/test/resources/__files/Macro/ServiceMacroActivateDeleteUnassign.json
@@ -7,6 +7,9 @@
 			"modelName": "MOW AVPN vMX BV vPE 1 Service",
 			"modelVersion": "10.0"
 		},
+		"cloudConfiguration": {
+			"cloudOwner" : "my-custom-cloud-owner"
+		},
 		"owningEntity": {
 			"owningEntityId": "038d99af-0427-42c2-9d15-971b99b9b489",
 			"owningEntityName": "PACKET CORE"
diff --git a/bpmn/so-bpmn-tasks/src/test/resources/__files/Macro/ServiceMacroAssign.json b/bpmn/so-bpmn-tasks/src/test/resources/__files/Macro/ServiceMacroAssign.json
index 51caddd..ddb118e 100644
--- a/bpmn/so-bpmn-tasks/src/test/resources/__files/Macro/ServiceMacroAssign.json
+++ b/bpmn/so-bpmn-tasks/src/test/resources/__files/Macro/ServiceMacroAssign.json
@@ -7,6 +7,9 @@
 			"modelName": "MOW AVPN vMX BV vPE 1 Service",
 			"modelVersion": "10.0"
 		},
+		"cloudConfiguration": {
+			"cloudOwner" : "my-custom-cloud-owner"
+		},
 		"owningEntity": {
 			"owningEntityId": "038d99af-0427-42c2-9d15-971b99b9b489",
 			"owningEntityName": "PACKET CORE"
diff --git a/bpmn/so-bpmn-tasks/src/test/resources/__files/Macro/ServiceMacroAssignNoCloud.json b/bpmn/so-bpmn-tasks/src/test/resources/__files/Macro/ServiceMacroAssignNoCloud.json
new file mode 100644
index 0000000..51caddd
--- /dev/null
+++ b/bpmn/so-bpmn-tasks/src/test/resources/__files/Macro/ServiceMacroAssignNoCloud.json
@@ -0,0 +1,125 @@
+{
+	"requestDetails": {
+		"modelInfo": {
+			"modelType": "service",
+			"modelInvariantId": "5d48acb5-097d-4982-aeb2-f4a3bd87d31b",
+			"modelVersionId": "3c40d244-808e-42ca-b09a-256d83d19d0a",
+			"modelName": "MOW AVPN vMX BV vPE 1 Service",
+			"modelVersion": "10.0"
+		},
+		"owningEntity": {
+			"owningEntityId": "038d99af-0427-42c2-9d15-971b99b9b489",
+			"owningEntityName": "PACKET CORE"
+		},
+		"project": {
+			"projectName": "{some project name}"
+		},
+		"subscriberInfo": {
+			"globalSubscriberId": "{some subscriber id}"
+		},
+		"requestInfo": {
+			"productFamilyId": "a9a77d5a-123e-4ca2-9eb9-0b015d2ee0fb",
+			"source": "VID",
+			"suppressRollback": true,
+			"requestorId": "xxxxxx"
+		},
+		"requestParameters": {
+			"subscriptionServiceType": "VMX",
+			"aLaCarte": false,
+			"userParams": [
+				{
+					"service": {
+						"modelInfo": {
+							"modelType": "service",
+							"modelName": "MOW AVPN vMX BV vPE 1 Service",
+							"modelVersionId": "3c40d244-808e-42ca-b09a-256d83d19d0a"
+						},
+						"instanceParams": [],
+						"resources": {
+							"vnfs": [
+								{
+									"modelInfo": {
+										"modelType": "vnf",
+										"modelName": "2016-73_MOW-AVPN-vPE-BV-L",
+										"modelVersionId": "7f40c192-f63c-463e-ba94-286933b895f8",
+										"modelCustomizationName": "2016-73_MOW-AVPN-vPE-BV-L 0",
+										"modelCustomizationId": "ab153b6e-c364-44c0-bef6-1f2982117f04"
+									},
+									"cloudConfiguration": {
+										"lcpCloudRegionId": "mdt1",
+										"tenantId": "88a6ca3ee0394ade9403f075db23167e"
+									},
+									"platform": {
+										"platformName": "test"
+									},
+									"lineOfBusiness": {
+										"lineOfBusinessName": "someValue"
+									},
+									"productFamilyId": "a9a77d5a-123e-4ca2-9eb9-0b015d2ee0fb",
+									"instanceParams": [],
+									"vfModules": [
+										{
+											"modelInfo": {
+												"modelType": "vfModule",
+												"modelName": "201673MowAvpnVpeBvL..AVPN_base_vPE_BV..module-0",
+												"modelVersionId": "4c75f813-fa91-45a4-89d0-790ff5f1ae79",
+												"modelCustomizationId": "a25e8e8c-58b8-4eec-810c-97dcc1f5cb7f"
+											},
+											"instanceParams": [
+												{
+													"vmx_int_net_len": "24"
+												}
+											]
+										},
+										{
+											"modelInfo": {
+												"modelType": "vfModule",
+												"modelName": "201673MowAvpnVpeBvL..AVPN_vRE_BV..module-1",
+												"modelVersionId": "56e2b103-637c-4d1a-adc8-3a7f4a6c3240",
+												"modelCustomizationId": "72d9d1cd-f46d-447a-abdb-451d6fb05fa8"
+											},
+											"instanceParams": [
+												{
+													"availability_zone_0": "mtpocdv-kvm-az01",
+													"vre_a_volume_size_0": "100"
+												}
+											]
+										},
+										{
+											"modelInfo": {
+												"modelType": "vfModule",
+												"modelName": "201673MowAvpnVpeBvL..AVPN_vRE_BV..module-1",
+												"modelVersionId": "56e2b103-637c-4d1a-adc8-3a7f4a6c3240",
+												"modelCustomizationId": "72d9d1cd-f46d-447a-abdb-451d6fb05fa8"
+											},
+											"instanceParams": [
+												{
+													"availability_zone_0": "mtpocdv-kvm-az01",
+													"vre_a_volume_size_0": "50"
+												}
+											]
+										},
+										{
+											"modelInfo": {
+												"modelType": "vfModule",
+												"modelName": "201673MowAvpnVpeBvL..AVPN_vPFE_BV..module-2",
+												"modelVersionId": "f555558f-d538-4876-8ffa-b102650fad64",
+												"modelCustomizationId": "da4d4327-fb7d-4311-ac7a-be7ba60cf969"
+											},
+											"instanceParams": [
+												{
+													"availability_zone_0": "mtpocdv-kvm-az01",
+													"vmx_vpfe_int_ip_0": "192.168.0.16"
+												}
+											]
+										}
+									]
+								}
+							]
+						}
+					}
+				}
+			]
+		}
+	}
+}
\ No newline at end of file
diff --git a/bpmn/so-bpmn-tasks/src/test/resources/application-test.yaml b/bpmn/so-bpmn-tasks/src/test/resources/application-test.yaml
index 7ecb5aa..210854e 100644
--- a/bpmn/so-bpmn-tasks/src/test/resources/application-test.yaml
+++ b/bpmn/so-bpmn-tasks/src/test/resources/application-test.yaml
@@ -185,6 +185,10 @@
   host: http://localhost:${wiremock.server.port}
   uri: /api/oof/v1/placement
   headers.auth: Basic dGVzdDp0ZXN0cHdk
+org:
+  onap:
+    so:
+      cloud-owner: att-aic
 spring:
   datasource:
     jdbc-url: jdbc:mariadb://localhost:3307/camundabpmn