Casablanca: AAI vnfm-list 17/69817/1
authorKanagaraj Manickam k00365106 <kanagaraj.manickam@huawei.com>
Thu, 4 Oct 2018 09:50:08 +0000 (15:20 +0530)
committerKanagaraj Manickam k00365106 <kanagaraj.manickam@huawei.com>
Thu, 4 Oct 2018 09:50:08 +0000 (15:20 +0530)
Issue-ID: CLI-122

Change-Id: I758c2cd8dc68c3145f493ee2107d536b768c1a1e
Signed-off-by: Kanagaraj Manickam k00365106 <kanagaraj.manickam@huawei.com>
products/onap-casablanca/features/aai/src/main/resources/open-cli-sample/esr/vnfm/vnfm-list-schema-casablanca-moco.json [new file with mode: 0644]
products/onap-casablanca/features/aai/src/main/resources/open-cli-sample/esr/vnfm/vnfm-list-schema-casablanca-sample.yaml [new file with mode: 0644]
products/onap-casablanca/features/aai/src/main/resources/open-cli-schema/esr/vnfm/vnfm-list-schema-casablanca.yaml [new file with mode: 0644]

diff --git a/products/onap-casablanca/features/aai/src/main/resources/open-cli-sample/esr/vnfm/vnfm-list-schema-casablanca-moco.json b/products/onap-casablanca/features/aai/src/main/resources/open-cli-sample/esr/vnfm/vnfm-list-schema-casablanca-moco.json
new file mode 100644 (file)
index 0000000..5ae1057
--- /dev/null
@@ -0,0 +1,25 @@
+[ {\r
+  "request" : {\r
+    "method" : "get",\r
+    "uri" : "/aai/v13/external-system/esr-vnfm-list",\r
+    "headers" : {\r
+      "Authorization" : "Basic QUFJOkFBSQ==",\r
+      "X-FromAppId" : "ONAP CLI",\r
+      "Accept" : "application/json",\r
+      "X-TransactionId" : "req-3a30a455-1807-42f2-a3c9-2e62b5c42e20",\r
+      "Content-Type" : "application/json"\r
+    },\r
+    "json" : null\r
+  },\r
+  "response" : {\r
+    "status" : 200,\r
+    "json" : {\r
+      "esr-vnfm" : [ {\r
+        "vnfm-id" : "3c96d72b-7fd8-45f7-a9bb-c9d270001eb8",\r
+        "vim-id" : "6a47cd3d-a24c-4d71-b47d-bfe729acce7b",\r
+        "certificate-url" : "",\r
+        "resource-version" : "1538645099584"\r
+      } ]\r
+    }\r
+  }\r
+} ]
\ No newline at end of file
diff --git a/products/onap-casablanca/features/aai/src/main/resources/open-cli-sample/esr/vnfm/vnfm-list-schema-casablanca-sample.yaml b/products/onap-casablanca/features/aai/src/main/resources/open-cli-sample/esr/vnfm/vnfm-list-schema-casablanca-sample.yaml
new file mode 100644 (file)
index 0000000..e115559
--- /dev/null
@@ -0,0 +1,14 @@
+open_cli_sample_version: 1.0
+name: vnfm-list
+version: onap-casablanca
+samples:
+  sample1:
+    name: vnfm-list
+    input: 
+    moco: vnfm-list-schema-casablanca-moco.json
+    output: |
+      +--------------------------------------+--------------------------------------+------------------+------------------+
+      |vnfm-id                               |vim-id                                |certificate-url   |resource-version  |
+      +--------------------------------------+--------------------------------------+------------------+------------------+
+      |3c96d72b-7fd8-45f7-a9bb-c9d270001eb8  |6a47cd3d-a24c-4d71-b47d-bfe729acce7b  |                  |1538645099584     |
+      +--------------------------------------+--------------------------------------+------------------+------------------+
diff --git a/products/onap-casablanca/features/aai/src/main/resources/open-cli-schema/esr/vnfm/vnfm-list-schema-casablanca.yaml b/products/onap-casablanca/features/aai/src/main/resources/open-cli-schema/esr/vnfm/vnfm-list-schema-casablanca.yaml
new file mode 100644 (file)
index 0000000..7da08cd
--- /dev/null
@@ -0,0 +1,60 @@
+# Copyright 2018 Huawei Technologies Co., Ltd.
+#
+# Licensed under the Apache License, Version 2.0 (the "License");
+# you may not use this file except in compliance with the License.
+# You may obtain a copy of the License at
+#
+#     http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+
+open_cli_schema_version: 1.0
+
+name: vnfm-list
+
+description: List the configured vnfm
+
+
+info:
+  product: onap-casablanca
+  service: aai
+  author: ONAP CLI Team onap-discuss@lists.onap.org
+
+results:
+  direction: landscape
+  attributes:
+    - name: vnfm-id
+      description: Onap vnfm id
+      scope: short
+      type: string
+    - name: vim-id
+      description: Onap vnfm id
+      scope: short
+      type: string
+    - name: certificate-url
+      description: Onap vnfm certificate-url
+      scope: short
+      type: string
+    - name: resource-version
+      description: Onap vnfm resource version
+      scope: short
+      type: string
+
+http:
+  service:
+    auth: basic
+    mode: direct
+  request:
+    uri: /aai/v13/external-system/esr-vnfm-list
+    method: GET
+  success_codes:
+    - 200
+  result_map:
+    vnfm-id: $b{$.esr-vnfm.[*].vnfm-id}
+    vim-id: $b{$.esr-vnfm.[*].vim-id}
+    certificate-url: $b{$.esr-vnfm.[*].certificate-url}
+    resource-version: $b{$.esr-vnfm.[*].resource-version}