Feature 10910: Migration of Openstack based VM instances 60/11960/2
authorelumalai <deepika.e@tataelxsi.co.in>
Thu, 28 Apr 2022 11:14:35 +0000 (16:44 +0530)
committergarciadeblas <gerardo.garciadeblas@telefonica.com>
Tue, 24 May 2022 11:25:49 +0000 (13:25 +0200)
Added OpenAPI specifications for Migration of Openstack based VM instances
from OSM

Change-Id: If4bf4494aa001a94f5b7d82280ac7ed6f62f6f64
Signed-off-by: elumalai <deepika.e@tataelxsi.co.in>
osm-openapi.yaml

index 02e92f7..ac6791a 100644 (file)
@@ -1661,6 +1661,62 @@ paths:
           $ref: '#/components/responses/UnexpectedError'
         default:
           $ref: '#/components/responses/UnexpectedError'
+  '/nslcm/v1/ns_instances/{nsInstanceId}/migrate':
+    parameters:
+      - name: nsInstanceId
+        in: path
+        required: true
+        description: NS Instance ID
+        schema:
+          type: string
+    post:
+      tags:
+        - "NS instances"
+      summary: Migrate VNFs in a NS instance
+      description: |
+        Migrate the VNFs and VDUs in a NS instance. The precondition is
+        that the NS instance must have been created and must be in
+        INSTANTIATED state. As a result of the success of this operation,
+        the NFVO creates a "NS Lifecycle Operation Occurrence" resource
+        for the request, and the NS instance state remains INSTANTIATED.
+      operationId: migrateNSinstance
+      requestBody:
+        $ref: '#/components/requestBodies/NSinstanceMigrateRequest'
+      responses:
+        '202':
+          description: Accepted
+          headers:
+            Location:
+              description: |
+                It must point to the new "NS Lifecycle Operation Occurrence"
+                resource, i.e. an URI like ".../ns_lcm_op_occs/{nsLcmOpOccId}"
+              schema:
+                type: string
+                format: uri
+        '400':
+          $ref: '#/components/responses/BadRequest'
+        '401':
+          $ref: '#/components/responses/Unauthorized'
+        '403':
+          $ref: '#/components/responses/Forbidden'
+        '404':
+          $ref: '#/components/responses/NotFound'
+        '405':
+          $ref: '#/components/responses/MethodNotAllowed'
+        '406':
+          $ref: '#/components/responses/NotAcceptable'
+        '409':
+          $ref: '#/components/responses/Conflict'
+        '422':
+          $ref: '#/components/responses/UnprocessableEntity'
+        '500':
+          $ref: '#/components/responses/InternalServerError'
+        '503':
+          $ref: '#/components/responses/ServiceUnavailable'
+        '5XX':
+          $ref: '#/components/responses/UnexpectedError'
+        default:
+          $ref: '#/components/responses/UnexpectedError'
   '/nslcm/v1/ns_instances/{nsInstanceId}/terminate':
     parameters:
       - name: nsInstanceId
@@ -7046,6 +7102,28 @@ components:
             Flag to indicate whether or not to run day1 primitives for the VDU (default: false).
           type: boolean
           default: false
+    NSinstanceMigrateRequest:
+      description: >
+        This type represents request parameters for the "Migrate" operation. This operation supports the migration of an NS
+        instance by migrating one or more of the VDUs that are part of this NS.
+      type: object
+      properties:
+        vnfInstanceId:
+          type: string
+        migrateToHost:
+          type: string
+        vdu:
+          type: object
+          properties:
+            vduId:
+              type: string
+            vduCountIndex:
+              type: integer
+          required:
+            - vduId
+      required:
+        - vnfInstanceId
+      additionalProperties: false
     TerminateNsRequest:
       type: object
       properties:
@@ -9033,6 +9111,14 @@ components:
         application/yaml:
           schema:
             $ref: '#/components/schemas/HealNsRequest'
+    NSinstanceMigrateRequest:
+      content:
+        application/json:
+          schema:
+            $ref: '#/components/schemas/NSinstanceMigrateRequest'
+        application/yaml:
+          schema:
+            $ref: '#/components/schemas/NSinstanceMigrateRequest'
     ScaleNsRequest:
       content:
         application/json: