aboutsummaryrefslogtreecommitdiffstats
path: root/src/main/resources
diff options
context:
space:
mode:
authorMatthieuGeerebaert <matthieu.geerebaert@orange.com>2018-03-28 17:12:51 +0200
committerMatthieuGeerebaert <matthieu.geerebaert@orange.com>2018-04-03 23:36:25 +0200
commit9ac6c3cc7e3f4aec9ba69e7a5bb0800471c4e8dc (patch)
tree55122c3e6f668250d19d917e668066cf8647f125 /src/main/resources
parent99bf586a6eb9799c4f33e43976d741f2807ea287 (diff)
Add service inventory
- Add service inventory operations get and find - Consumes AAI - Add tests Change-Id: If04ada259b7a172c1dbaac3649047cdb2d9dd5bc Issue-ID: EXTAPI-39 Signed-off-by: MatthieuGeerebaert <matthieu.geerebaert@orange.com>
Diffstat (limited to 'src/main/resources')
-rw-r--r--src/main/resources/application-localhost.properties16
-rw-r--r--src/main/resources/jolt/findServiceInventory.json24
-rw-r--r--src/main/resources/jolt/getServiceInventory.json44
3 files changed, 84 insertions, 0 deletions
diff --git a/src/main/resources/application-localhost.properties b/src/main/resources/application-localhost.properties
index 58b13f6..e753488 100644
--- a/src/main/resources/application-localhost.properties
+++ b/src/main/resources/application-localhost.properties
@@ -1,7 +1,23 @@
# LOGGING
logging.level.org.onap.nbi=DEBUG
+# ONAP
+onap.lcpCloudRegionId=RegionOne
+onap.tenantId=31047205ce114b60833b23e400d6a535
+onap.cloudOwner=CloudOwner
+
+# NBI
+nbi.url=http://127.0.0.1:8080/nbi/api/v1
+
# SDC
sdc.host=http://127.0.0.1:8090
sdc.header.ecompInstanceId=Rene
sdc.header.authorization=Basic YWFpOktwOGJKNFNYc3pNMFdYbGhhazNlSGxjc2UyZ0F3ODR2YW9HR21KdlV5MlU=
+
+# AAI
+aai.host=http://127.0.0.1:8090
+aai.header.authorization=Basic QUFJOkFBSQ==
+aai.api.id=AAI
+
+
+
diff --git a/src/main/resources/jolt/findServiceInventory.json b/src/main/resources/jolt/findServiceInventory.json
new file mode 100644
index 0000000..7188edc
--- /dev/null
+++ b/src/main/resources/jolt/findServiceInventory.json
@@ -0,0 +1,24 @@
+[
+ {
+ "operation": "shift",
+ "spec": {
+ "*": {
+ "service-instance-id": "[&1].id",
+ "service-instance-name": "[&1].name",
+ "service-type": "[&1].serviceSpecification.name",
+ "model-version-id": "[&1].serviceSpecification.id"
+ }
+ }
+ },
+ {
+ "operation": "default",
+ "spec": {
+ "*": {
+ "relatedParty": {
+
+ "role": "ONAPcustomer"
+ }
+ }
+ }
+ }
+] \ No newline at end of file
diff --git a/src/main/resources/jolt/getServiceInventory.json b/src/main/resources/jolt/getServiceInventory.json
new file mode 100644
index 0000000..df4f14c
--- /dev/null
+++ b/src/main/resources/jolt/getServiceInventory.json
@@ -0,0 +1,44 @@
+[
+ {
+ "operation": "shift",
+ "spec": {
+ "service-instance-id": "id",
+ "service-instance-name": "name",
+ "model-version-id" : "serviceSpecification.id",
+ "model-invariant-id": "serviceSpecification.invariantUUID",
+ "vnfs" : {
+ "*": {
+ "vnf-id": "supportingResource[&1].id",
+ "related-link": "supportingResource[&1].href",
+ "vnf-name": "supportingResource[&1].name",
+ "prov-status": "supportingResource[&1].status",
+ "model-invariant-id": "supportingResource[&1].modelInvariantId",
+ "model-version-id": "supportingResource[&1].modelVersionId",
+ "model-customisation-id": "supportingResource[&1].status"
+
+ }
+ }
+ }
+ },
+ {
+ "operation": "default",
+ "spec": {
+ "type": "service-instance",
+ "hasStarted": "yes",
+ "@type": "serviceONAP",
+ "serviceSpecification" : {
+ "@type" :"ONAPservice"
+ },
+ "supportingResource[]" : {
+ "*": {
+ "@referredType": "ONAP resource"
+ }
+
+ },
+ "relatedParty" : {
+ "role" :"ONAPcustomer"
+ }
+
+ }
+ }
+] \ No newline at end of file