summaryrefslogtreecommitdiffstats
path: root/products/onap-dublin/features
diff options
context:
space:
mode:
authorKanagaraj Manickam <mkr1481@gmail.com>2019-08-29 16:43:05 +0530
committerKanagaraj Manickam k00365106 <kanagaraj.manickam@huawei.com>2019-08-29 16:43:05 +0530
commita866260dc004b2d27edcb0abe48de47db98dce1a (patch)
treeb8e2c4b125229e9d86cc9b930aab1517afb4b3f4 /products/onap-dublin/features
parent5d673cd489a857c9dbe754de1b83d68a4735c4b0 (diff)
complex-disassociate update
Change-Id: I84c3080d55970aef6ccc9a5e206e9d92b5691dc6 Issue-ID: CLI-166 Signed-off-by: Kanagaraj Manickam k00365106 <kanagaraj.manickam@huawei.com>
Diffstat (limited to 'products/onap-dublin/features')
-rw-r--r--products/onap-dublin/features/aai/src/main/resources/open-cli-sample/infra/complex/complex-disassociate-schema-dublin-moco.json25
-rw-r--r--products/onap-dublin/features/aai/src/main/resources/open-cli-sample/infra/complex/complex-disassociate-schema-dublin-sample.yaml10
-rw-r--r--products/onap-dublin/features/aai/src/main/resources/open-cli-schema/infra/complex/complex-disassociate-schema-dublin.yaml63
3 files changed, 98 insertions, 0 deletions
diff --git a/products/onap-dublin/features/aai/src/main/resources/open-cli-sample/infra/complex/complex-disassociate-schema-dublin-moco.json b/products/onap-dublin/features/aai/src/main/resources/open-cli-sample/infra/complex/complex-disassociate-schema-dublin-moco.json
new file mode 100644
index 00000000..5f102ff1
--- /dev/null
+++ b/products/onap-dublin/features/aai/src/main/resources/open-cli-sample/infra/complex/complex-disassociate-schema-dublin-moco.json
@@ -0,0 +1,25 @@
+[ {
+ "request" : {
+ "method" : "delete",
+ "uri" : "/aai/v14/cloud-infrastructure/cloud-regions/cloud-region/OCOMP/RegionOVP/relationship-list/relationship",
+ "headers" : {
+ "Authorization" : "Basic QUFJOkFBSQ==",
+ "X-FromAppId" : "ONAP CLI",
+ "Accept" : "application/json",
+ "X-TransactionId" : "req-26265a69-7c6c-4315-bddb-0e9548880b15",
+ "Content-Type" : "application/json"
+ },
+ "json" : {
+ "related-to" : "complex",
+ "related-link" : "/aai/v11/cloud-infrastructure/complexes/complex/ocomp-region",
+ "relationship-data" : [ {
+ "relationship-key" : "complex.physical-location-id",
+ "relationship-value" : "ocomp-region"
+ } ]
+ }
+ },
+ "response" : {
+ "status" : 204,
+ "json" : null
+ }
+} ] \ No newline at end of file
diff --git a/products/onap-dublin/features/aai/src/main/resources/open-cli-sample/infra/complex/complex-disassociate-schema-dublin-sample.yaml b/products/onap-dublin/features/aai/src/main/resources/open-cli-sample/infra/complex/complex-disassociate-schema-dublin-sample.yaml
new file mode 100644
index 00000000..3bb86584
--- /dev/null
+++ b/products/onap-dublin/features/aai/src/main/resources/open-cli-sample/infra/complex/complex-disassociate-schema-dublin-sample.yaml
@@ -0,0 +1,10 @@
+open_cli_sample_version: 1.0
+name: complex-disassociate
+version: onap-dublin
+samples:
+ sample1:
+ name: complex-disassociate
+ input: --format json --complex-name ocomp-region --cloud-owner OCOMP --cloud-region RegionOVP
+ moco: complex-disassociate-schema-dublin-moco.json
+ output: |
+ [{}]
diff --git a/products/onap-dublin/features/aai/src/main/resources/open-cli-schema/infra/complex/complex-disassociate-schema-dublin.yaml b/products/onap-dublin/features/aai/src/main/resources/open-cli-schema/infra/complex/complex-disassociate-schema-dublin.yaml
new file mode 100644
index 00000000..39480c00
--- /dev/null
+++ b/products/onap-dublin/features/aai/src/main/resources/open-cli-schema/infra/complex/complex-disassociate-schema-dublin.yaml
@@ -0,0 +1,63 @@
+# Copyright © Intel Corporation 2019
+#
+# 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: complex-disassociate
+description: Disassociate a cloud region with a cloud complex
+
+info:
+ product: onap-dublin
+ service: aai
+ author: Intel ONAP HPA integration team (itohan.ukponmwan@intel.com)
+
+parameters:
+ - name: complex-name
+ description: name of cloud complex
+ type: string
+ short_option: x
+ long_option: complex-name
+ is_optional: false
+ - name: cloud-region
+ description: name of registered cloud-region
+ type: string
+ short_option: y
+ long_option: cloud-region
+ is_optional: false
+ - name: cloud-owner
+ description: name of cloud-owner
+ type: string
+ short_option: z
+ long_option: cloud-owner
+ is_optional: false
+
+http:
+ service:
+ auth: basic
+ mode: direct
+ request:
+ uri: /aai/v14/cloud-infrastructure/cloud-regions/cloud-region/${cloud-owner}/${cloud-region}/relationship-list/relationship
+ method: DELETE
+ body: '{
+ "related-to": "complex",
+ "related-link": "/aai/v11/cloud-infrastructure/complexes/complex/${complex-name}",
+ "relationship-data": [
+ {
+ "relationship-key": "complex.physical-location-id",
+ "relationship-value": "${complex-name}"
+ }]
+ }'
+ success_codes:
+ - 200
+ - 204
+ - 404