From 6da7037b8ea752e2111099d83358b7b6758bb300 Mon Sep 17 00:00:00 2001 From: mxzhao <mengxuan.zhao@eglobalmark.com> Date: Mon, 10 Dec 2018 16:39:05 +0100 Subject: [PATCH] workflow SOL003 VNF LCM --- .../ScaleVNFTaskWorkflow.robot | 58 ++ .../SubscriptionKeywords.robot | 41 ++ .../VnfLcmMntOperationKeywords.robot | 124 ++++ .../jsons/grantRequest.json | 16 + .../schemas/grant.schema.json | 628 ++++++++++++++++++ .../variables.txt | 4 +- 6 files changed, 868 insertions(+), 3 deletions(-) create mode 100644 SOL003/VNFLifecycleManagement-API_egm/ScaleVNFTaskWorkflow.robot create mode 100644 SOL003/VNFLifecycleManagement-API_egm/SubscriptionKeywords.robot create mode 100644 SOL003/VNFLifecycleManagement-API_egm/VnfLcmMntOperationKeywords.robot create mode 100644 SOL003/VNFLifecycleManagement-API_egm/jsons/grantRequest.json create mode 100644 SOL003/VNFLifecycleManagement-API_egm/schemas/grant.schema.json diff --git a/SOL003/VNFLifecycleManagement-API_egm/ScaleVNFTaskWorkflow.robot b/SOL003/VNFLifecycleManagement-API_egm/ScaleVNFTaskWorkflow.robot new file mode 100644 index 00000000..58fd69d1 --- /dev/null +++ b/SOL003/VNFLifecycleManagement-API_egm/ScaleVNFTaskWorkflow.robot @@ -0,0 +1,58 @@ +*** Settings *** +Resource variables.txt +Resource VnfLcmMntOperationKeywords.robot +Resource SubscriptionKeywords.robot +Library REST http://${VNFM_HOST}:${VNFM_PORT} spec=SOL003-VNFLifecycleManagement-API.yaml +Library OperatingSystem +Library BuiltIn +Library Collections +Library JSONLibrary + + +*** Test Cases *** +Precondition Checks + Check resource instantiated + ${LccnSubscriptions}= Check subscriptions about one VNFInstance and operation type ${vnfInstanceId} VnfLcmOperationOccurrenceNotification operationType=SCALE + Set Suite Variable ${LccnSubscriptions} + ${scaleInfo}= Get Vnf Scale Info ${vnfInstanceId} + +POST Scale Out a vnfInstance + [Documentation] Test ID: 5.x.y.x + ... Test title: Scale out VNF operation + ... Test objective: The objective is to test a scale out of an existing VNF instance + ... Pre-conditions: VNF instance in INSTANTIATED state (Test ID: 5.a.b.c) + ... Reference: section 5.4.5 - SOL003 v2.4.1 + ... Config ID: Config_prod_VNFM + ... Applicability: Scale operation is supported for the VNF (as capability in the VNFD) + ... NFVO is not subscribed for + ... Post-Conditions: VNF instance still in INSTANTIATED state and VNF was scaled + + ${headers} ${status}= Send VNFScaleOut request + Check Response Status 202 ${status} + ${vnfLcmOpOccId}= Get VnfLcmOpOccId ${headers} + +Wait for Notification - STARTING + Deliver a notification - Operation Occurence + ${VnfLcmOccInstance}= Get VnfLcmOccInstance ${vnfLcmOpOccId} + Check operationState STARTING ${VnfLcmOccInstance} + +Granting exchange + Create a new Grant - Synchronous mode + +Wait for Notification - PROCESSING + Deliver a notification - Operation Occurence + ${VnfLcmOccInstance}= Get VnfLcmOccInstance ${vnfLcmOpOccId} + Check operationState PROCESSING ${VnfLcmOccInstance} + +Wait for Notification - COMPLETED + Deliver a notification - Operation Occurence + ${VnfLcmOccInstance}= Get VnfLcmOccInstance ${vnfLcmOpOccId} + Check operationState COMPLETED ${VnfLcmOccInstance} + +Postcondition Checks + Check resource instantiated + ${newScaleInfo}= Get Vnf Scale Info ${vnfInstanceId} + #TODO: How to check if VNF is scaled? + + + \ No newline at end of file diff --git a/SOL003/VNFLifecycleManagement-API_egm/SubscriptionKeywords.robot b/SOL003/VNFLifecycleManagement-API_egm/SubscriptionKeywords.robot new file mode 100644 index 00000000..860107dc --- /dev/null +++ b/SOL003/VNFLifecycleManagement-API_egm/SubscriptionKeywords.robot @@ -0,0 +1,41 @@ +*** Settings *** +Resource variables.txt +Library REST http://${VNFM_HOST}:${VNFM_PORT} spec=SOL003-VNFLifecycleManagement-API.yaml +Library OperatingSystem +Library BuiltIn +Library JSONLibrary +Library MockServerLibrary + +*** Variables *** +${sleep_interval} 20s + +*** Keywords *** +Check subscriptions about one VNFInstance and operation type + [Arguments] ${vnfInstanceId} ${notificationType} ${operationType}="" ${operationState}="" + Set Headers {"Accept": "${ACCEPT}"} + Run Keyword If ${AUTH_USAGE} == 1 Set Headers {"Authorization": "${AUTHORIZATION}"} + Run Keyword If ${notificationType}=="VnfIdentifierCreationNotification" or ${notificationType}=="VnfIdentifierDeletionNotification" GET ${apiRoot}/${apiName}/${apiVersion}/subscriptions?vnfInstanceIds=${vnfInstanceId}¬ificationTypes=${notificationType} + ... ELSE GET ${apiRoot}/${apiName}/${apiVersion}/subscriptions?vnfInstanceIds=${vnfInstanceId}¬ificationTypes=${notificationType}&operationTypes=${operationType}&operationStates=${operationState} + Integer response status 200 + Array response body minItems=1 + ${body} Output response body + [Return] ${body} + + +Deliver a notification - Operation Occurence + log The POST method delivers a notification from the server to the client. + ${json}= Get File schemas/vnfLcmOperationOccurrenceNotification.schema.json + ${BODY}= evaluate json.loads('''${json}''') json + Log Creating mock request and response to handle vnfLcmOperationOccurrenceNotification + &{req}= Create Mock Request Matcher POST ${notification_ep} body_type='JSON_SCHEMA' body=${BODY} + &{rsp}= Create Mock Response 204 headers="Content-Type: application/json" body_type='JSON_SCHEMA' + Create Mock Expectation ${req} ${rsp} + Sleep ${sleep_interval} + Log Verifying results + Verify Mock Expectation ${req} + Log Cleaning the endpoint + Clear Requests ${notification_ep} + + + + \ No newline at end of file diff --git a/SOL003/VNFLifecycleManagement-API_egm/VnfLcmMntOperationKeywords.robot b/SOL003/VNFLifecycleManagement-API_egm/VnfLcmMntOperationKeywords.robot new file mode 100644 index 00000000..8dd62028 --- /dev/null +++ b/SOL003/VNFLifecycleManagement-API_egm/VnfLcmMntOperationKeywords.robot @@ -0,0 +1,124 @@ +*** Settings *** +Resource variables.txt +Library REST http://${VNFM_HOST}:${VNFM_PORT} spec=SOL003-VNFLifecycleManagement-API.yaml +Library OperatingSystem +Library BuiltIn +Library JSONLibrary +Library JSONSchemaLibrary schemas/ + +*** Variables *** +${GRANT_POLLING_TOT} 2 +${GRANT_POLLING_INTERVAL} 5s +${SCALE_POLLING_TOT} 10 +${SCALE_POLLING_INTERVAL} 15s + + +*** Keywords *** + +Get Vnf Instance + [Arguments] ${vnfInstanceId} + Set Headers {"Accept":"${ACCEPT}"} + Set Headers {"Content-Type": "${CONTENT_TYPE}"} + Run Keyword If ${AUTH_USAGE} == 1 Set Headers {"Authorization":"${AUTHORIZATION}"} + Get ${apiRoot}/${apiName}/${apiVersion}/vnf_instances/${vnfInstanceId} + ${body}= Output response body + ${json}= evaluate json.loads('''${body}''') json + [Return] ${json} + +Check resource Instantiated + Set Headers {"Accept":"${ACCEPT}"} + Set Headers {"Content-Type": "${CONTENT_TYPE}"} + Run Keyword If ${AUTH_USAGE} == 1 Set Headers {"Authorization":"${AUTHORIZATION}"} + Get ${apiRoot}/${apiName}/${apiVersion}/vnf_instances/${vnfInstanceId} + Integer response status 200 + String response body instantiationState INSTANTIATED + +Get Vnf Scale Info + [Arguments] ${vnfInstanceId} + ${vnfInstance}= Get Vnf Instance ${vnfInstanceId} + ${scaleInfo}= Get Value From Json ${vnfInstance} $..scaleStatus + [Return] ${scaleInfo} + +Check Response Status + [Arguments] ${expected_status} ${status} + Should Be Equal ${expected_status} ${status} + +Send VNFscaleOut Request + Log Trying to scale a vnf Instance + Set Headers {"Accept":"${ACCEPT}"} + Set Headers {"Content-Type": "${CONTENT_TYPE}"} + Run Keyword If ${AUTH_USAGE} == 1 Set Headers {"Authorization":"${AUTHORIZATION}"} + ${body}= Get File json/scaleVnfOutRequest.json + Post ${apiRoot}/${apiName}/${apiVersion}/vnf_instances/${vnfInstanceId}/scale ${body} + ${headers}= Output response headers + ${json}= evaluate json.loads('''${headers}''') json + ${status}= Output response status + [Return] ${json} ${status} + +Get VnfLcmOpOccId + [Arguments] ${headers} + ${vnfLcmOpOccId}= Get Value From Json ${headers} $..Location + Should Not Be Empty ${vnfLcmOpOccId} + [Return] ${vnfLcmOpOccId} + +Get VnfLcmOccInstance + [Arguments] ${vnfLcmOpOccId} + GET ${apiRoot}/${apiName}/${apiVersion}/vnf_lcm_op_occs/${vnfLcmOpOccId} + ${body}= Output response body + ${json}= evaluate json.loads('''${body}''') json + [Return] ${json} + +Check operationState + [Arguments] ${operationState} ${VnfLcmOccInstance} + ${currentState}= Get Value From Json ${VnfLcmOccInstance} $..operationState + Should Be Equal ${currentState} ${operationState} + + +Check Operation Status Transition + [Arguments] ${vnfLcmOpOccId} ${initial_status} ${final_status} ${POLLING_TOT} ${POLLING_INTERVAL} + :FOR ${INDEX} IN RANGE 1 ${POLLING_TOT} + \ GET ${apiRoot}/${apiName}/${apiVersion}/vnf_lcm_op_occs/${vnfLcmOpOccId} + \ ${status}= Output response status + \ Check Response Status 200 ${status} + \ ${body}= Output response body + \ ${json}= evaluate json.loads('''${body}''') json + \ ${operationState}= Get Value From Json ${json} $..operationState + \ Run Keyword If Should Not Be Equal ${initial_status} ${operationState} Exit For Loop + \ Sleep ${POLLING_INTERVAL} + Should Be Equal ${final_status} ${operationState} + +Create a new Grant - Synchronous mode + Log Request a new Grant for a VNF LCM operation by POST to ${apiRoot}/${apiName}/${apiVersion}/grants + Pass Execution If ${SYNC_MODE} == 0 The Granting process is asynchronous mode. Skipping the test + Set Headers {"Accept":"${ACCEPT}"} + Set Headers {"Content-Type": "${CONTENT_TYPE}"} + Run Keyword If ${AUTH_USAGE} == 1 Set Headers {"Authorization":"${AUTHORIZATION}"} + ${body}= Get File json/grantRequest.json + Post ${apiRoot}/${apiName}/${apiVersion}/grants ${body} + Integer response status 201 + Log Status code validated + ${headers}= Output response headers + Should Contain ${headers} Location + ${contentType}= Output response headers Content-Type + Should Contain ${contentType} ${CONTENT_TYPE} + ${result}= Output response body + ${json}= evaluate json.loads('''${result}''') json + Validate Json grant.schema.json ${json} + Log Validation OK + +Create a new Grant - Asynchronous mode + Log Request a new Grant for a VNF LCM operation by POST to ${apiRoot}/${apiName}/${apiVersion}/grants + Pass Execution If ${SYNC_MODE} == 1 The Granting process is synchronous mode. Skipping the test + Set Headers {"Accept": "${ACCEPT}"} + Set Headers {"Content-Type": "${CONTENT_TYPE}"} + Run Keyword If ${AUTH_USAGE} == 1 Set Headers {"Authorization": "${AUTHORIZATION}"} + ${body}= Get File json/grantRequest.json + Post ${apiRoot}/${apiName}/${apiVersion}/grants ${body} + Output response + Integer response status 202 + Log Status code validated + ${headers}= Output response headers + Should Contain ${headers} Location + ${contentType}= Output response headers Content-Type + Should Contain ${contentType} ${CONTENT_TYPE} + Log Validation OK \ No newline at end of file diff --git a/SOL003/VNFLifecycleManagement-API_egm/jsons/grantRequest.json b/SOL003/VNFLifecycleManagement-API_egm/jsons/grantRequest.json new file mode 100644 index 00000000..74b32682 --- /dev/null +++ b/SOL003/VNFLifecycleManagement-API_egm/jsons/grantRequest.json @@ -0,0 +1,16 @@ +{ + "vnfInstanceId": "myVnfInstanceId", + "vnfLcmOpOccId": "myLcmOccId", + "vnfdId": "myVnF", + "flavourId": "string", + "operation": "INSTANTIATE", + "isAutomaticInvocation": true, + "_links": { + "vnfLcmOpOcc": { + "href": "string" + }, + "vnfInstance": { + "href": "string" + } + } +} \ No newline at end of file diff --git a/SOL003/VNFLifecycleManagement-API_egm/schemas/grant.schema.json b/SOL003/VNFLifecycleManagement-API_egm/schemas/grant.schema.json new file mode 100644 index 00000000..bd0bf8ea --- /dev/null +++ b/SOL003/VNFLifecycleManagement-API_egm/schemas/grant.schema.json @@ -0,0 +1,628 @@ +{ + "description": "This type represents a grant.\n", + "type": "object", + "required": [ + "id", + "vnfInstanceId", + "vnfLcmOpOccId", + "_links" + ], + "properties": { + "id": { + "description": "An identifier with the intention of being globally unique.\n", + "type": "string" + }, + "vnfInstanceId": { + "description": "An identifier with the intention of being globally unique.\n", + "type": "string" + }, + "vnfLcmOpOccId": { + "description": "An identifier with the intention of being globally unique.\n", + "type": "string" + }, + "vimConnections": { + "description": "Provides information regarding VIM connections that are approved to be used by the VNFM to allocate resources, and provides parameters of these VIM connections. The VNFM shall update the \" vimConnectionInfo\" attribute of the \"VnfInstance\" structure by adding unknown entries received in this attribute. This attribute is not intended for the modification of VimConnection entries passed earlier; for that, the VnfInfoModificationRequest structure shall be used. This attribute shall only be supported when VNF-related Resource Management in direct mode is applicable. In direct mode, this parameter shall be absent if the VIM information was configured to the VNFM in another way, present otherwise. This interface allows to signal the use of multiple VIMs per VNF. However, due to the partial support of this feature in the present release, it is recommended in the present document that the number of entries in the \"vims\" attribute in the Grant is not greater than 1.\n", + "type": "array", + "items": { + "description": "This type represents parameters to connect to a VIM for managing the resources of a VNF instance. This structure is used to convey VIM-related parameters over the Or-Vnfm interface. Additional parameters for a VIM may be configured into the VNFM by means outside the scope of the present document, and bound to the identifier of that VIM.\n", + "type": "object", + "required": [ + "id", + "vimType" + ], + "properties": { + "id": { + "description": "An identifier with the intention of being globally unique.\n", + "type": "string" + }, + "vimId": { + "description": "An identifier with the intention of being globally unique.\n", + "type": "string" + }, + "vimType": { + "description": "Discriminator for the different types of the VIM information. The value of this attribute determines the structure of the \"interfaceInfo\" and \"accessInfo\" attributes, based on the type of the VIM. The set of permitted values is expected to change over time as new types or versions of VIMs become available. The ETSI NFV registry of VIM-related information provides access to information about VimConnectionInfo definitions for various VIM types. The structure of the registry is defined in Annex C of SOL003.\n", + "type": "string" + }, + "interfaceInfo": { + "description": "This type represents a list of key-value pairs. The order of the pairs in the list is not significant. In JSON, a set of key- value pairs is represented as an object. It shall comply with the provisions defined in clause 4 of IETF RFC 7159.\n", + "type": "object" + }, + "accessInfo": { + "description": "This type represents a list of key-value pairs. The order of the pairs in the list is not significant. In JSON, a set of key- value pairs is represented as an object. It shall comply with the provisions defined in clause 4 of IETF RFC 7159.\n", + "type": "object" + }, + "extra": { + "description": "This type represents a list of key-value pairs. The order of the pairs in the list is not significant. In JSON, a set of key- value pairs is represented as an object. It shall comply with the provisions defined in clause 4 of IETF RFC 7159.\n", + "type": "object" + } + } + } + }, + "zones": { + "description": "Identifies resource zones where the resources are approved to be allocated by the VNFM.\n", + "type": "array", + "items": { + "description": "This type provides information regarding a resource zone.\n", + "type": "object", + "required": [ + "id", + "zoneId" + ], + "properties": { + "id": { + "description": "An identifier that is unique within a limited local scope other than above listed identifiers, such as within a complex data structure or within a request-response pair. Representation: string of variable length.\n", + "type": "string" + }, + "zoneId": { + "description": "An identifier with the intention of being globally unique.\n", + "type": "string" + }, + "vimConnectionId": { + "description": "An identifier with the intention of being globally unique.\n", + "type": "string" + }, + "resourceProviderId": { + "description": "An identifier with the intention of being globally unique.\n", + "type": "string" + } + } + } + }, + "zoneGroups": { + "description": "Information about groups of resource zones that are related and that the NFVO has chosen to fulfil a zoneGroup constraint in the GrantVnfLifecycleOperation request. This information confirms that the NFVO has honoured the zoneGroup constraints that were passed as part of \"placementConstraints\" in the GrantRequest.\n", + "type": "array", + "items": { + "description": "This type provides information regarding a resource zone group. A resource zone group is a group of one or more related resource zones which can be used in resource placement constraints. To fulfil such constraint, the NFVO may decide to place a resource into any zone that belongs to a particular group. NOTE: A resource zone group can be used to support overflow from one resource zone into another, in case a particular deployment supports only non-elastic resource zones.\n", + "type": "object", + "required": [ + "zoneId" + ], + "properties": { + "zoneId": { + "description": "References of identifiers of \"ZoneInfo\" structures, each of which provides information about a resource zone that belongs to this group.\n", + "type": "array", + "items": { + "description": "An identifier that is unique within a limited local scope other than above listed identifiers, such as within a complex data structure or within a request-response pair. Representation: string of variable length.\n", + "type": "string" + } + } + } + } + }, + "computeReservationId": { + "description": "An identifier maintained by the VIM or other resource provider. It is expected to be unique within the VIM instance.\n", + "type": "string" + }, + "networkReservationId": { + "description": "An identifier maintained by the VIM or other resource provider. It is expected to be unique within the VIM instance.\n", + "type": "string" + }, + "storageReservationId": { + "description": "An identifier maintained by the VIM or other resource provider. It is expected to be unique within the VIM instance.\n", + "type": "string" + }, + "addResources": { + "description": "List of resources that are approved to be added, with one entry per resource.\n", + "type": "array", + "items": { + "description": "This type contains information about a Compute, storage or network resource whose addition/update/deletion was granted.\n", + "type": "object", + "required": [ + "resourceDefinitionId" + ], + "properties": { + "resourceDefinitionId": { + "description": "An identifier that is unique within a limited local scope other than above listed identifiers, such as within a complex data structure or within a request-response pair. Representation: string of variable length.\n", + "type": "string" + }, + "reservationId": { + "description": "An identifier with the intention of being globally unique.\n", + "type": "string" + }, + "vimConnectionId": { + "description": "An identifier with the intention of being globally unique.\n", + "type": "string" + }, + "resourceProviderId": { + "description": "An identifier with the intention of being globally unique.\n", + "type": "string" + }, + "zoneId": { + "description": "An identifier that is unique within a limited local scope other than above listed identifiers, such as within a complex data structure or within a request-response pair. Representation: string of variable length.\n", + "type": "string" + }, + "resourceGroupId": { + "description": "An identifier maintained by the VIM or other resource provider. It is expected to be unique within the VIM instance.\n", + "type": "string" + } + } + } + }, + "tempResources": { + "description": "List of resources that are approved to be temporarily instantiated during the runtime of the lifecycle operation, with one entry per resource.\n", + "type": "array", + "items": { + "description": "This type contains information about a Compute, storage or network resource whose addition/update/deletion was granted.\n", + "type": "object", + "required": [ + "resourceDefinitionId" + ], + "properties": { + "resourceDefinitionId": { + "description": "An identifier that is unique within a limited local scope other than above listed identifiers, such as within a complex data structure or within a request-response pair. Representation: string of variable length.\n", + "type": "string" + }, + "reservationId": { + "description": "An identifier with the intention of being globally unique.\n", + "type": "string" + }, + "vimConnectionId": { + "description": "An identifier with the intention of being globally unique.\n", + "type": "string" + }, + "resourceProviderId": { + "description": "An identifier with the intention of being globally unique.\n", + "type": "string" + }, + "zoneId": { + "description": "An identifier that is unique within a limited local scope other than above listed identifiers, such as within a complex data structure or within a request-response pair. Representation: string of variable length.\n", + "type": "string" + }, + "resourceGroupId": { + "description": "An identifier maintained by the VIM or other resource provider. It is expected to be unique within the VIM instance.\n", + "type": "string" + } + } + } + }, + "removeResources": { + "description": "List of resources that are approved to be removed, with one entry per resource.\n", + "type": "array", + "items": { + "description": "This type contains information about a Compute, storage or network resource whose addition/update/deletion was granted.\n", + "type": "object", + "required": [ + "resourceDefinitionId" + ], + "properties": { + "resourceDefinitionId": { + "description": "An identifier that is unique within a limited local scope other than above listed identifiers, such as within a complex data structure or within a request-response pair. Representation: string of variable length.\n", + "type": "string" + }, + "reservationId": { + "description": "An identifier with the intention of being globally unique.\n", + "type": "string" + }, + "vimConnectionId": { + "description": "An identifier with the intention of being globally unique.\n", + "type": "string" + }, + "resourceProviderId": { + "description": "An identifier with the intention of being globally unique.\n", + "type": "string" + }, + "zoneId": { + "description": "An identifier that is unique within a limited local scope other than above listed identifiers, such as within a complex data structure or within a request-response pair. Representation: string of variable length.\n", + "type": "string" + }, + "resourceGroupId": { + "description": "An identifier maintained by the VIM or other resource provider. It is expected to be unique within the VIM instance.\n", + "type": "string" + } + } + } + }, + "updateResources": { + "description": "List of resources that are approved to be modified, with one entry per resource.\n", + "type": "array", + "items": { + "description": "This type contains information about a Compute, storage or network resource whose addition/update/deletion was granted.\n", + "type": "object", + "required": [ + "resourceDefinitionId" + ], + "properties": { + "resourceDefinitionId": { + "description": "An identifier that is unique within a limited local scope other than above listed identifiers, such as within a complex data structure or within a request-response pair. Representation: string of variable length.\n", + "type": "string" + }, + "reservationId": { + "description": "An identifier with the intention of being globally unique.\n", + "type": "string" + }, + "vimConnectionId": { + "description": "An identifier with the intention of being globally unique.\n", + "type": "string" + }, + "resourceProviderId": { + "description": "An identifier with the intention of being globally unique.\n", + "type": "string" + }, + "zoneId": { + "description": "An identifier that is unique within a limited local scope other than above listed identifiers, such as within a complex data structure or within a request-response pair. Representation: string of variable length.\n", + "type": "string" + }, + "resourceGroupId": { + "description": "An identifier maintained by the VIM or other resource provider. It is expected to be unique within the VIM instance.\n", + "type": "string" + } + } + } + }, + "vimAssets": { + "description": "Information about assets for the VNF that are managed by the NFVO in the VIM, such as software images and virtualised compute resource flavours. This attribute is not intended for the modification of vimAssets entries passed earlier. Modification of VIM assets during the lifetime of a VNF instance is not necessary, since it is expected that all applicable assets have been on boarded into the VIM before the VNF is instantiated.\n", + "type": "object", + "properties": { + "computeResourceFlavours": { + "description": "Mappings between virtual compute descriptors defined in the VNFD and compute resource flavours managed in the VIM.\n", + "type": "array", + "items": { + "description": "If the VIM requires the use of virtual compute resource flavours during compute resource instantiation, it is assumed that such flavours are selected or created by the NFVO based on the information in the virtual compute descriptor defined in the VNFD. This type defines the mapping between a virtual compute descriptor in the VNFD and the corresponding compute resource flavour managed by the NFVO in the VIM.\n", + "type": "object", + "required": [ + "vnfdVirtualComputeDescId", + "vimFlavourId" + ], + "properties": { + "vimConnectionId": { + "description": "An identifier with the intention of being globally unique.\n", + "type": "string" + }, + "resourceProviderId": { + "description": "An identifier with the intention of being globally unique.\n", + "type": "string" + }, + "vnfdVirtualComputeDescId": { + "description": "An identifier that is unique within a VNF descriptor.\n", + "type": "string" + }, + "vimFlavourId": { + "description": "An identifier maintained by the VIM or other resource provider. It is expected to be unique within the VIM instance.\n", + "type": "string" + } + } + } + }, + "softwareImages": { + "description": "Mappings between software images defined in the VNFD and software images managed in the VIM.\n", + "type": "array", + "items": { + "description": "This type contains a mapping between a software image definition the VNFD and the corresponding software image managed by the NFVO in the VIM which is needed during compute resource instantiation.\n", + "type": "object", + "required": [ + "vnfdSoftwareImageId", + "vimSoftwareImageId" + ], + "properties": { + "vimConnectionId": { + "description": "An identifier with the intention of being globally unique.\n", + "type": "string" + }, + "resourceProviderId": { + "description": "An identifier with the intention of being globally unique.\n", + "type": "string" + }, + "vnfdSoftwareImageId": { + "description": "An identifier that is unique within a VNF descriptor.\n", + "type": "string" + }, + "vimSoftwareImageId": { + "description": "An identifier maintained by the VIM or other resource provider. It is expected to be unique within the VIM instance.\n", + "type": "string" + } + } + } + } + } + }, + "extVirtualLinks": { + "description": "Information about external VLs to connect the VNF to. External and/or externally-managed internal VLs can be passed in VNF lifecycle management operation requests such as InstantiateVnf or ChangeVnfFlavor, and/or in the grant response. The NFVO may choose to override in the grant response external and/or externally-managed VL instances that have been passed previously in the associated VNF lifecycle management request, if the lifecycle management request has originated from the NFVO itself.\n", + "type": "array", + "items": { + "description": "This type represents an external VL.\n", + "type": "object", + "required": [ + "id", + "resourceId", + "extCps" + ], + "properties": { + "id": { + "description": "An identifier with the intention of being globally unique.\n", + "type": "string" + }, + "vimConnectionId": { + "description": "An identifier with the intention of being globally unique.\n", + "type": "string" + }, + "resourceProviderId": { + "description": "An identifier with the intention of being globally unique.\n", + "type": "string" + }, + "resourceId": { + "description": "An identifier maintained by the VIM or other resource provider. It is expected to be unique within the VIM instance.\n", + "type": "string" + }, + "extCps": { + "description": "External CPs of the VNF to be connected to this external VL.\n", + "type": "array", + "items": { + "description": "This type represents configuration information for external CPs created from a CPD.\n", + "type": "object", + "required": [ + "cpdId" + ], + "properties": { + "cpdId": { + "description": "An identifier that is unique within a VNF descriptor.\n", + "type": "string" + }, + "cpConfig": { + "description": "List of instance data that need to be configured on the CP instances created from the respective CPD.\n", + "type": "array", + "items": { + "description": "This type represents an externally provided link port or network address information per instance of an external connection point. In case a link port is provided, the VNFM shall use that link port when connecting the external CP to the external VL. In a link port is not provided, the VNFM shall create a link port on the external VL, and use that link port to connect the external CP to the external VL.\n", + "type": "object", + "properties": { + "cpInstanceId": { + "description": "An identifier that is unique for the respective type within a VNF instance, but may not be globally unique.\n", + "type": "string" + }, + "linkPortId": { + "description": "An identifier with the intention of being globally unique.\n", + "type": "string" + }, + "cpProtocolData": { + "description": "Parameters for configuring the network protocols on the link port that connects the CP to a VL. The following conditions apply to the attributes \"linkPortId\" and \"cpProtocolData\": * The \"linkPortId\" and \"cpProtocolData\" attributes shall both be absent for the deletion of an existing external CP instance\n addressed by cpInstanceId. \n* At least one of these attributes shall be present for a to-be-created external CP instance or an existing external\n CP instance.\n* If the \"linkPortId\" attribute is absent, the VNFM shall create a link port.\n* If the \"cpProtocolData\" attribute is absent, the \"linkPortId\" attribute shall be provided referencing a pre-created link port,\n and the VNFM can use means outside the scope of the present\n document to obtain the pre-configured address information for the\n connection point from the resource representing the link port.\n* If both \"cpProtocolData\" and \"linkportId\" are provided, the API consumer shall ensure that the cpProtocolData can be used with the\n pre-created link port referenced by \"linkPortId\".\n", + "type": "array", + "items": { + "description": "This type represents network protocol data.\n", + "type": "object", + "required": [ + "layerProtocol" + ], + "properties": { + "layerProtocol": { + "description": "Identifier of layer(s) and protocol(s). This attribute allows to signal the addition of further types of layer and protocol in future versions of the present document in a backwards-compatible way. In the current version of the present document, only IP over Ethernet is supported.\n", + "type": "string", + "enum": [ + "IP_OVER_ETHERNET" + ] + }, + "ipOverEthernet": { + "description": "This type represents network address data for IP over Ethernet.\n", + "type": "object", + "properties": { + "macAddress": { + "description": "A MAC address. Representation: string that consists of groups of two hexadecimal digits, separated by hyphens or colons.\n", + "type": "string", + "format": "MAC" + }, + "ipAddresses": { + "description": "List of IP addresses to assign to the CP instance. Each entry represents IP address data for fixed or dynamic IP address assignment per subnet. If this attribute is not present, no IP address shall be assigned.\n", + "type": "array", + "items": { + "type": "object", + "required": [ + "type" + ], + "properties": { + "type": { + "description": "The type of the IP addresses. Permitted values: IPV4, IPV6.\n", + "type": "string", + "enum": [ + "IPV4", + "IPV6" + ] + }, + "fixedAddresses": { + "description": "Fixed addresses to assign (from the subnet defined by \"subnetId\" if provided). Exactly one of \"fixedAddresses\", \"numDynamicAddresses\" or \"ipAddressRange\" shall be present.\n", + "type": "array", + "items": { + "description": "An IPV4 or IPV6 address. Representation: In case of an IPV4 address, string that consists of four decimal integers separated by dots, each integer ranging from 0 to 255. In case of an IPV6 address, string that consists of groups of zero to four hexadecimal digits, separated by colons.\n", + "type": "string", + "format": "IP" + } + }, + "numDynamicAddresses": { + "description": "Number of dynamic addresses to assign (from the subnet defined by \"subnetId\" if provided). Exactly one of \"fixedAddresses\", \"numDynamicAddresses\" or \"ipAddressRange\" shall be present.\n", + "type": "integer" + }, + "addressRange": { + "description": "An IP address range to be used, e.g. in case of egress connections. In case this attribute is present, IP addresses from the range will be used.\n", + "type": "object", + "required": [ + "minAddress", + "maxAddress" + ], + "properties": { + "minAddress": { + "description": "An IPV4 or IPV6 address. Representation: In case of an IPV4 address, string that consists of four decimal integers separated by dots, each integer ranging from 0 to 255. In case of an IPV6 address, string that consists of groups of zero to four hexadecimal digits, separated by colons.\n", + "type": "string", + "format": "IP" + }, + "maxAddress": { + "description": "An IPV4 or IPV6 address. Representation: In case of an IPV4 address, string that consists of four decimal integers separated by dots, each integer ranging from 0 to 255. In case of an IPV6 address, string that consists of groups of zero to four hexadecimal digits, separated by colons.\n", + "type": "string", + "format": "IP" + } + } + }, + "subnetId": { + "description": "An identifier maintained by the VIM or other resource provider. It is expected to be unique within the VIM instance.\n", + "type": "string" + } + } + } + } + } + } + } + } + } + } + } + } + } + } + }, + "extLinkPorts": { + "description": "Externally provided link ports to be used to connect external connection points to this external VL. If this attribute is not present, the VNFM shall create the link ports on the external VL.\n", + "type": "array", + "items": { + "description": "This type represents an externally provided link port to be used to connect an external connection point to an external VL.\n", + "type": "object", + "required": [ + "id", + "resourceHandle" + ], + "properties": { + "id": { + "description": "An identifier with the intention of being globally unique.\n", + "type": "string" + }, + "resourceHandle": { + "required": [ + "vimConnectionId", + "resourceId" + ], + "type": "object", + "description": "This type represents the information that allows addressing a virtualised resource that is used by a VNF instance. Information about the resource is available from the VIM.\n", + "properties": { + "vimConnectionId": { + "description": "An identifier with the intention of being globally unique.\n", + "type": "string" + }, + "resourceProviderId": { + "description": "An identifier with the intention of being globally unique.\n", + "type": "string" + }, + "resourceId": { + "description": "An identifier maintained by the VIM or other resource provider. It is expected to be unique within the VIM instance.\n", + "type": "string" + }, + "vimLevelResourceType": { + "description": "Type of the resource in the scope of the VIM or the resource provider.\n", + "type": "string" + } + } + } + } + } + } + } + } + }, + "extManagedVirtualLinks": { + "description": "Information about internal VLs that are managed by other entities than the VNFM. The indication of externally-managed internal VLs is needed in case networks have been pre-configured for use with certain VNFs, for instance to ensure that these networks have certain properties such as security or acceleration features, or to address particular network topologies. The present document assumes that externally-managed internal VLs are managed by the NFVO and created towards the VIM. External and/or externally-managed internal VLs can be passed in VNF lifecycle management operation requests such as InstantiateVnf or ChangeVnfFlavor, and/or in the grant response. The NFVO may choose to override in the grant response external and/or externally-managed VL instances that have been passed previously in the associated VNF lifecycle management request, if the lifecycle management request has originated from the NFVO itself.\n", + "type": "array", + "items": { + "type": "object", + "required": [ + "id", + "virtualLinkDescId", + "resourceId" + ], + "properties": { + "id": { + "description": "An identifier with the intention of being globally unique.\n", + "type": "string" + }, + "virtualLinkDescId": { + "description": "An identifier that is unique within a VNF descriptor.\n", + "type": "string" + }, + "vimConnectionId": { + "description": "An identifier with the intention of being globally unique.\n", + "type": "string" + }, + "resourceProviderId": { + "description": "An identifier with the intention of being globally unique.\n", + "type": "string" + }, + "resourceId": { + "description": "An identifier maintained by the VIM or other resource provider. It is expected to be unique within the VIM instance.\n", + "type": "string" + } + } + } + }, + "additionalParams": { + "description": "This type represents a list of key-value pairs. The order of the pairs in the list is not significant. In JSON, a set of key- value pairs is represented as an object. It shall comply with the provisions defined in clause 4 of IETF RFC 7159.\n", + "type": "object" + }, + "_links": { + "description": "Links to resources related to this resource.\n", + "type": "object", + "required": [ + "self", + "vnfLcmOpOcc", + "vnfInstance" + ], + "properties": { + "self": { + "description": "This type represents a link to a resource.\n", + "type": "object", + "required": [ + "href" + ], + "properties": { + "href": { + "description": "URI of the referenced resource.\n", + "type": "string", + "format": "url" + } + } + }, + "vnfLcmOpOcc": { + "description": "This type represents a link to a resource.\n", + "type": "object", + "required": [ + "href" + ], + "properties": { + "href": { + "description": "URI of the referenced resource.\n", + "type": "string", + "format": "url" + } + } + }, + "vnfInstance": { + "description": "This type represents a link to a resource.\n", + "type": "object", + "required": [ + "href" + ], + "properties": { + "href": { + "description": "URI of the referenced resource.\n", + "type": "string", + "format": "url" + } + } + } + } + } + } +} \ No newline at end of file diff --git a/SOL003/VNFLifecycleManagement-API_egm/variables.txt b/SOL003/VNFLifecycleManagement-API_egm/variables.txt index 9f8c953a..f28f6d38 100644 --- a/SOL003/VNFLifecycleManagement-API_egm/variables.txt +++ b/SOL003/VNFLifecycleManagement-API_egm/variables.txt @@ -36,6 +36,4 @@ ${notification_port} 9091 ${VnfLcmOperationOccurrenceNotification} {} ${VnfIdentifierCreationNotification} {} ${VnfIdentifierDeletionNotification} {} -${callback_uri} http://localhost -${callback_port} 8888 -${callback_endpoint} /subscribe +${SYNC_MODE} 0 \ No newline at end of file -- GitLab