Date: Fri, 29 Mar 2024 13:36:41 +0000 (UTC) Message-ID: <1861949931.130742.1711719401263@aws-us-west-2-onap-confluence-1.web.codeaurora.org> Subject: Exported From Confluence MIME-Version: 1.0 Content-Type: multipart/related; boundary="----=_Part_130741_961720263.1711719401260" ------=_Part_130741_961720263.1711719401260 Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: quoted-printable Content-Location: file:///C:/exported.html
Author: Badr Eddine Aouled Yahia - Orange
Reviewed by:Jose Manuel Sanchez Vilchez, Christian Destr=C3=A9 - Orange<= /p>
This page provides a deep investigation on t= he mechanisms of deployment and closed loop for the vFW use-case on ONAP Be= ijing release.
The vFW service is composed of the following components:
vPKG VNF:
=E2=80=93Packet generator: sends periodically different volumes of traff= ic to the sink through the firewall (vFw)
vFWSNK VNF:
=E2=80=93Firewall: reports the volume of traffic passing through to the = DCAE collector (VES collector). The vFW has no real firewalling functionali= ty.
=E2=80=93Traffic sink: provides a graphical representation (bar charts) = showing the volume of incoming traffic.
The vFW close loop scenario consists in applying policy= rules that aim to re-adjust the traffic volume when high threshold (700 pa= ckets/10s) or low threshold (300 packets/10s) are crossed. In fact, the DCA= E collects events from the vFW, applies analytics (Threshold Crossing Analy= tics: TCA microservice) and publishes events to DMaap. When detecting the t= riggering event, the policy engine executes the operational policy via the = APP-C that modifies vPKG application configurations in order to adjust the = traffic volume to 500 packet per 10 seconds.
After onboarding and distributing a service, ONAP execution-time provide= s tools and processes to deploy a service.
From an ONAP user perspective, the operation of service deployment in ON= AP consists in an ordered set of actions performed through scripts or using= the VID portal to trigger instantiation in SO.
In general, a service in ONAP is the composition of several elements tha= t consists in VNFs, Networks, VF-modules and volume groups.
In order to fully deploy a service via VID portal, three levels of insta= ntiation are identified:
Each step of instantiation corresponds to a set of orchestration tasks p= erformed by the SO component. In fact, when recieving a request to create a= service instance, the SO selects a process that defines a workflow of acti= ons in order to accomplish the service instantiation. The process includes = series of tasks to be executed by ONAP execution-time components.
Service deployment involves the following main SO components:
The closed loop concept in ONAP allows an automatic recovery= of faults reported by traps or alarms and provides automated capacity mana= gement when performance thresholds are crossed.It uses feedbacks to control= and optimize the behavior of monitored elements in order to automatically = respond to service conditions without human intervention.
The execution of a closed loop involves several components. = In fact, the DCAE is responsible for collecting and analysing collected dat= a in order to publish events to DMaap. The policy engine allows to trigger = a response according to configuration policies when detecting critical even= ts. Finally, an operational policy is executed by ONAP orchestrator or cont= rollers.
The closed loop design is provided by CLAMP that allows the = creation and distribution of a CL workflow.
After design and distribution stages, the vFW service is ready to be dep= loyed.Three main user actions are performed in VID portal in order to fully= deploy the service. These actions correspond to three HTTP requests sent t= o SO.
From a high level perspective, each VID requ= est towards SO triggers the execution of an orchestration workflow. In fact= , When receiving a request, the API Handler stores an orchestration request= in request_db and selects a BPMN workflow from Camunda_db to be executed b= y the orchestration engine (Camunda). The workflow specifies a sequence of = orchestration tasks to be performed by ONAP execution-time components. The = process includes recursive calls to other orchestration sub-processes.
To each BPMN corresponds a groovy script exe= cuted by the camunda engine that allows to perform actions or invoke other = ONAP components to execute an action via Resource and Controller adapters.<= /p>
In the VID portal, the demo user deploys the= service:
The user specifies the input data and confir= ms:
User action in VID portal:
The user action corresponds to an HTTP POST request from VID towards SO = to trigger service instance creation: POST /ecomp/mso/infra/serviceInsta= nces/v6
POST /ecomp/mso/infra/serviceInstances/v6 HTTP/1.1 Authorization: Basic SW5mcmFQb3J0YWxDbGllbnQ6cGFzc3dvcmQxJA=3D=3D X-FromAppId: VID X-ECOMP-RequestID: dffdfdbb-b42e-43b6-b2e0-199181141abd Content-Type: application/json User-Agent: Jersey/2.23.1 (HttpUrlConnection 1.8.0_171) Cache-Control: no-cache Pragma: no-cache Host: vm1.mso.simpledemo.onap.org:8080 Accept: text/html, image/gif, image/jpeg, *; q=3D.2, */*; q=3D.2 Connection: keep-alive { =20 "requestDetails":{ =20 "requestInfo":{ =20 "instanceName":"vfw_svc_1607", "source":"VID", "suppressRollback":false, "requestorId":"demo" }, "modelInfo":{ =20 "modelType":"service", "modelInvariantId":"46c0d35f-4a34-4f5b-9ee3-fd65f6f74ac2", "modelVersionId":"84909c11-1a62-47b3-9aed-59c2ec5c891d", "modelName":"vfw_svc", "modelVersion":"2.0" }, "requestParameters":{ =20 "userParams":[ =20 ], "subscriptionServiceType":"vFWCL", "aLaCarte":true }, "subscriberInfo":{ =20 "globalSubscriberId":"Demonstration", "subscriberName":"Demonstration" }, "project":{ =20 "projectName":"Project-Demonstration" }, "owningEntity":{ =20 "owningEntityId":"75c646bf-6b09-4759-b65d-ae366a40da91", "owningEntityName":"OE-Demonstration" } } }
HTTP/1.1 202 Accepted {"requestReferences":{"instanceId":"d39d0833-ea8a-45be-8863-76715697cdb3","= requestId":"08390a82-88f8-429f-9dd9-fa673bf5ed38"}}
The VID request triggers the execution of CreateGenericALaCarteServiceInstance BPM= N process.
This BPMN process calls respectively two sub-processes: Decompos= eService and DoCreateServiceInstance
the DoCerateServiceInstance BPMN process includes GenericPutService process that allows to put service instan= ce in the inventory via HTTP PUT request sent by Camunda engine.
PUT /business/customers/customer/{global-customer-id}/service-subscripti= ons/service-subscription/{service-type}/service-instances/service-instance/= {service-instance-id}
Exchanges between SO and A&AI components are encrypted.
We can verify that service is created in the inventory: GET https://<= aai1_ip>:8443/aai/v13//business/customers/customer/Demonstration/service= -subscriptions/service-subscription/vFWCL/service-instances/service-instanc= e/ce035b11-77f5-41ff-a6e8-e38fc8d4ccd4
The VID follows the service orchestration request status by sending GET = requests to SO:
GET /ecomp/mso/infra/orchestrationRequests/v6/08390a82-88f8-429f-9= dd9-fa673bf5ed38 HTTP/1.1 Authorization: Basic SW5mcmFQb3J0YWxDbGllbnQ6cGFzc3dvcmQxJA=3D=3D X-FromAppId: VID X-ECOMP-RequestID: 2ea804d4-9d5f-4ece-bf1e-95bc963c22ae User-Agent: Jersey/2.23.1 (HttpUrlConnection 1.8.0_171) Cache-Control: no-cache Pragma: no-cache Host: vm1.mso.simpledemo.onap.org:8080 Accept: text/html, image/gif, image/jpeg, *; q=3D.2, */*; q=3D.2 Connection: keep-alive
HTTP/1.1 200 OK Expires: 0 Cache-Control: no-cache, no-store, must-revalidate X-Powered-By: Undertow/1 Server: WildFly/10 Pragma: no-cache Date: Thu, 19 Jul 2018 14:50:05 GMT Connection: keep-alive Content-Type: application/json Content-Length: 1133 { =20 "request":{ =20 "requestId":"08390a82-88f8-429f-9dd9-fa673bf5ed38", "startTime":"Thu, 19 Jul 2018 14:49:55 GMT", "requestScope":"service", "requestType":"createInstance", "requestDetails":{ =20 "modelInfo":{ =20 "modelInvariantId":"46c0d35f-4a34-4f5b-9ee3-fd65f6f74ac2", "modelType":"service", "modelName":"vfw_svc", "modelVersion":"2.0", "modelVersionId":"84909c11-1a62-47b3-9aed-59c2ec5c891d" }, "requestInfo":{ =20 "source":"VID", "instanceName":"vfw_svc_1607", "suppressRollback":false, "requestorId":"demo" }, "subscriberInfo":{ =20 "globalSubscriberId":"Demonstration", "subscriberName":"Demonstration" }, "requestParameters":{ =20 "alaCarte":true, "subscriptionServiceType":"vFWCL", "aLaCarte":true }, "project":{ =20 "projectName":"Project-Demonstration" }, "owningEntity":{ =20 "owningEntityId":"75c646bf-6b09-4759-b65d-ae366a40da91", "owningEntityName":"OE-Demonstration" } }, "instanceReferences":{ =20 "serviceInstanceId":"d39d0833-ea8a-45be-8863-76715697cdb3", "serviceInstanceName":"vfw_svc_1607", "requestorId":"demo" }, "requestStatus":{ =20 "requestState":"COMPLETE", "statusMessage":"Service Instance was created successfully.", "percentProgress":100, "finishTime":"Thu, 19 Jul 2018 14:49:56 GMT" } } }
Mechanism analysis will be explained o= nly for the vFWSNK vnf and its module
The vFW service includes two vnfs, the mechanism is the same for the two= vnfs and their vf-module. So we will explain it for the vFWSNK vnf only.= p>
In the VID portal, the user adds a VNF node instance:
The user action corresponds to an HTTP POST request from VID towards SO = to trigger vnf instance creation: POST /ecomp/mso/infra/serviceInstances= /v6/{service_instance_id}/vnfs
POST /ecomp/mso/infra/serviceInstances/v6/d39d0833-ea8a-45be-8863-7671569= 7cdb3/vnfs HTTP/1.1 Authorization: Basic SW5mcmFQb3J0YWxDbGllbnQ6cGFzc3dvcmQxJA=3D=3D X-FromAppId: VID X-ECOMP-RequestID: 41dc6f28-b847-4190-9573-a762cb77ab30 Content-Type: application/json User-Agent: Jersey/2.23.1 (HttpUrlConnection 1.8.0_171) Cache-Control: no-cache Pragma: no-cache Host: vm1.mso.simpledemo.onap.org:8080 Accept: text/html, image/gif, image/jpeg, *; q=3D.2, */*; q=3D.2 Connection: keep-alive Content-Length: 1018 { =20 "requestDetails":{ =20 "requestInfo":{ =20 "instanceName":"vfw-vf", "source":"VID", "suppressRollback":false, "requestorId":"demo", "productFamilyId":"8eba27fe-89eb-4c32-9ee6-aa5428c7d962" }, "modelInfo":{ =20 "modelType":"vnf", "modelInvariantId":"c7582c77-5a11-471c-a24f-5347ec811cdd", "modelVersionId":"db0fbb27-fd0d-40eb-8491-0f4a48adaefe", "modelName":"vsp_vfwsnk_1607", "modelVersion":"2.0", "modelCustomizationId":"5365f464-3e2e-40be-9dc2-480c916bcf10", "modelCustomizationName":"vsp_vfwsnk_1607 0" }, "requestParameters":{ =20 "userParams":[ =20 ] }, "cloudConfiguration":{ =20 "lcpCloudRegionId":"fr2", "tenantId":"324b90de6e9a4ad88e93a100c2cedd5d" }, "lineOfBusiness":{ =20 "lineOfBusinessName":"LOB-Demonstration" }, "platform":{ =20 "platformName":"Platform-Demonstration" }, "relatedInstanceList":[ =20 { =20 "relatedInstance":{ =20 "instanceId":"d39d0833-ea8a-45be-8863-76715697cdb3", "modelInfo":{ =20 "modelType":"service", "modelName":"vfw_svc", "modelInvariantId":"46c0d35f-4a34-4f5b-9ee3-fd65f6f74ac2"= , "modelVersion":"2.0", "modelVersionId":"84909c11-1a62-47b3-9aed-59c2ec5c891d" } } } ] } }
HTTP/1.1 202 Accepted {"requestReferences":{"instanceId":"415932c3-f295-462a-b130-bdf5f33ced06","= requestId":"e4c03a55-5d64-4867-9177-ee2cf9146dc4"}}
The VID request triggers the execution of CreateVnfInfra BPMN process:
The main actions of this process are defined in the sub process = DoCreateVnf.
As specified in this sub process building blocks, the VNF instance creat=
ion invokes the following main actions:
=E2=80=A2Populate A&AI with a VNF instance data: Create (Put) G=
eneric Vnf (GenericPutVnf sub-process)
=E2=80=A2Call SDN-C adapter VNF topology assign: Call SDNC Adapter =
VNF Topology Assign
=E2=80=A2Call SDN-C adapter VNF topology activate: Call SDNC Adapte=
r VNF Topology Activate
=E2=80=A2Update orchestration status to active in A&AI: Update =
AAI Orchestration status to Active
As SDNC interaction is not enabled, only the first action (Create Generi= c Vnf) is performed.
GenericPutVnf sub-process populates the inventory with = the vnf instance data via Http PUT request (PUT /network/generic-vnfs/gener= ic-vnf/{vnf-id}) and establishes the relation between the vnf instance and = service instance.
We can verify that vnf instances and relationship with service instance = were created in the inventory: https://<aai1_ip>:8443/aai/v13/network/gen= eric-vnfs/generic-vnf/e1a9ac1b-b9a0-4424-8659-69426c8bfdc8
The VID follows the vnf orchestration request status by sending GET requ= ests to SO:
GET /ecomp/mso/infra/orchestrationRequests/v6/cfeb170d-7b0f-44db-8= 1e3-ff440fce43ea HTTP/1.1 Authorization: Basic SW5mcmFQb3J0YWxDbGllbnQ6cGFzc3dvcmQxJA=3D=3D X-FromAppId: VID X-ECOMP-RequestID: 0eaa4f8f-b6f0-4183-8f6b-bb1ba847efc8 User-Agent: Jersey/2.23.1 (HttpUrlConnection 1.8.0_171) Cache-Control: no-cache Pragma: no-cache Host: vm1.mso.simpledemo.onap.org:8080 Accept: text/html, image/gif, image/jpeg, *; q=3D.2, */*; q=3D.2 Connection: keep-aliv
HTTP/1.1 200 OK Expires: 0 Cache-Control: no-cache, no-store, must-revalidate X-Powered-By: Undertow/1 Server: WildFly/10 Pragma: no-cache Date: Thu, 19 Jul 2018 14:50:50 GMT Connection: keep-alive Content-Type: application/json Content-Length: 1511 { =20 "request":{ =20 "requestId":"cfeb170d-7b0f-44db-81e3-ff440fce43ea", "startTime":"Thu, 19 Jul 2018 14:50:40 GMT", "requestScope":"vnf", "requestType":"createInstance", "requestDetails":{ =20 "modelInfo":{ =20 "modelCustomizationName":"vsp_vfwsnk_1607 0", "modelInvariantId":"c7582c77-5a11-471c-a24f-5347ec811cdd", "modelType":"vnf", "modelName":"vsp_vfwsnk_1607", "modelVersion":"2.0", "modelVersionId":"db0fbb27-fd0d-40eb-8491-0f4a48adaefe", "modelCustomizationId":"5365f464-3e2e-40be-9dc2-480c916bcf10" }, "requestInfo":{ =20 "productFamilyId":"8eba27fe-89eb-4c32-9ee6-aa5428c7d962", "source":"VID", "instanceName":"vfw-vf", "suppressRollback":false, "requestorId":"demo" }, "relatedInstanceList":[ =20 { =20 "relatedInstance":{ =20 "instanceId":"d39d0833-ea8a-45be-8863-76715697cdb3", "modelInfo":{ =20 "modelInvariantId":"46c0d35f-4a34-4f5b-9ee3-fd65f6f74a= c2", "modelType":"service", "modelName":"vfw_svc", "modelVersion":"2.0", "modelVersionId":"84909c11-1a62-47b3-9aed-59c2ec5c891d= " } } } ], "cloudConfiguration":{ =20 "tenantId":"324b90de6e9a4ad88e93a100c2cedd5d", "lcpCloudRegionId":"fr2" }, "requestParameters":{ =20 }, "platform":{ =20 "platformName":"Platform-Demonstration" }, "lineOfBusiness":{ =20 "lineOfBusinessName":"LOB-Demonstration" } }, "instanceReferences":{ =20 "serviceInstanceId":"d39d0833-ea8a-45be-8863-76715697cdb3", "vnfInstanceId":"e1a9ac1b-b9a0-4424-8659-69426c8bfdc8", "vnfInstanceName":"vfw-vf", "requestorId":"demo" }, "requestStatus":{ =20 "requestState":"COMPLETE", "statusMessage":"Vnf has been created successfully.", "percentProgress":100, "finishTime":"Thu, 19 Jul 2018 14:50:41 GMT" } } }
In the vFW use-case, before creating the vf-module two steps should be p= erformed: Create vnf profile (in sdnc portal) and preload sdnc with vnf dat= a (using sdnc api http://<sdnc_ip>:8282/= apidoc/explorer/index.html ).
In the VID portal, user demo adds then vf-module:
The VID triggers vf-module creation via Http POST request towards SO: POST /ecomp/mso/infra/serviceInstances/v6/{service_instance_id}/vnfs/{vnf_= id}/vfModules
POST /ecomp/mso/infra/serviceInstances/v6/d39d0833-ea8a-45be-8863-7= 6715697cdb3/vnfs/e1a9ac1b-b9a0-4424-8659-69426c8bfdc8/vfModules HTTP/1.1 Authorization: Basic SW5mcmFQb3J0YWxDbGllbnQ6cGFzc3dvcmQxJA=3D=3D X-FromAppId: VID X-ECOMP-RequestID: 329b557c-3e3f-42c6-8b41-241a9bc0eb27 Content-Type: application/json User-Agent: Jersey/2.23.1 (HttpUrlConnection 1.8.0_171) Cache-Control: no-cache Pragma: no-cache Host: vm1.mso.simpledemo.onap.org:8080 Accept: text/html, image/gif, image/jpeg, *; q=3D.2, */*; q=3D.2 Connection: keep-alive Content-Length: 1272 { =20 "requestDetails":{ =20 "requestInfo":{ =20 "instanceName":"vfw-vf-module", "source":"VID", "suppressRollback":false, "requestorId":"demo" }, "modelInfo":{ =20 "modelType":"vfModule", "modelInvariantId":"08fa9f0d-4fb5-41ae-8cc3-8282333ff6aa", "modelVersionId":"f8d43f3f-8189-4eac-a122-b5a5e06ad3ab", "modelName":"VspVfwsnk1607..base_vfw..module-0", "modelVersion":"2", "modelCustomizationId":"bb084cb1-e8eb-4030-a2b7-931a3ae1c91f", "modelCustomizationName":"VspVfwsnk1607..base_vfw..module-0" }, "requestParameters":{ =20 "usePreload":true }, "cloudConfiguration":{ =20 "lcpCloudRegionId":"fr2", "tenantId":"324b90de6e9a4ad88e93a100c2cedd5d" }, "relatedInstanceList":[ =20 { =20 "relatedInstance":{ =20 "instanceId":"d39d0833-ea8a-45be-8863-76715697cdb3", "modelInfo":{ =20 "modelType":"service", "modelName":"vfw_svc", "modelInvariantId":"46c0d35f-4a34-4f5b-9ee3-fd65f6f74ac2"= , "modelVersion":"2.0", "modelVersionId":"84909c11-1a62-47b3-9aed-59c2ec5c891d" } } }, { =20 "relatedInstance":{ =20 "instanceId":"e1a9ac1b-b9a0-4424-8659-69426c8bfdc8", "modelInfo":{ =20 "modelType":"vnf", "modelName":"vsp_vfwsnk_1607", "modelInvariantId":"c7582c77-5a11-471c-a24f-5347ec811cdd"= , "modelVersion":"2.0", "modelVersionId":"db0fbb27-fd0d-40eb-8491-0f4a48adaefe", "modelCustomizationId":"5365f464-3e2e-40be-9dc2-480c916bc= f10", "modelCustomizationName":"vsp_vfwsnk_1607 0" } } } ] } }
HTTP/1.1 202 Accepted {"requestReferences":{"instanceId":"be0ae48e-029a-4efc-af46-d11bcf58c403","= requestId":"7b1b5758-d274-4305-aefc-289f1e614d7d"}}
The API handler selects a BPMN workflow called CreateVfModuleInfra.
In addition to vf-module creation, this BPMN process could perform scale= out operation for a vf-module instance but it is not the case for the vFW.=
The DoCreateVfModule is the main subprocess that define= s steps for creating the vf-module. It includes the following actions that = are performed in the vFW use-case deployment:
Query AAI for orchestration status
CreateAAIVfModule: subprocess that creates a vf-module instance obje= ct in the inventory:HTTP PUT /network/generic-vnfs/generic-vnf/{vnf-id}/vf-= modules/vf-module/{vf-module-id}
We can verify the vf-module instance in the inventory with GET request.<= /p>
3. Call SDNC adapter: Vf-module topology = assign
To perform this action, Camunda engine calls SDNC adapter via Http reque= st:POST /restconf/operations/VNF-API:vnf-topology-operation
<?xml version=3D"1.0" encoding=3D"UTF-8"?> <input xmlns=3D"org:onap:sdnctl:vnf"> <sdnc-request-header> <svc-request-id>7b1b5758-d274-4305-aefc-289f1e614d7d-1532011988= 473</svc-request-id> <svc-action>assign</svc-action> <svc-notification-url>http://c1.vm1.mso.simpledemo.openecomp.or= g:8080/adapters/rest/SDNCNotify</svc-notification-url> </sdnc-request-header> <request-information> <request-id>7b1b5758-d274-4305-aefc-289f1e614d7d</request-id= > <request-action>VNFActivateRequest</request-action> <source>VID</source> <notification-url /> </request-information> <service-information> <service-id>null</service-id> <service-type>null</service-type> <service-instance-id>d39d0833-ea8a-45be-8863-76715697cdb3</s= ervice-instance-id> <subscriber-name>notsurewecare</subscriber-name> </service-information> <vnf-request-information> <vnf-id>be0ae48e-029a-4efc-af46-d11bcf58c403</vnf-id> <vnf-type>VspVfwsnk1607..base_vfw..module-0</vnf-type> <vnf-name>vfw-vf-module</vnf-name> <generic-vnf-id>e1a9ac1b-b9a0-4424-8659-69426c8bfdc8</generi= c-vnf-id> <generic-vnf-name>vfw-vf</generic-vnf-name> <generic-vnf-type>vfw_svc/vsp_vfwsnk_1607 0</generic-vnf-typ= e> <aic-cloud-region>fr2</aic-cloud-region> <tenant>324b90de6e9a4ad88e93a100c2cedd5d</tenant> <use-preload>Y</use-preload> </vnf-request-information> </input>
This request triggers the execution of a set of Directed Graphs<= /strong>
Git repository of VNF-API DG json: https://git.onap=
.org/sdnc/oam/tree/platform-logic/vnfapi/src/main/json?h=3Dbeijing
<=
/span>
You can see Directed graphs by importing Json (to clipboard) in the SDNC= - DG dashboard http://<sdnc_ip>:3000
A DG implements a method that initiates a RPC when executed.
By parsing the request body fields, this DG calls a specific second DG b= ased on the use-preload value
This condition figures out in the POST request body with Y as value as&n= bsp; we have manually preloaded SDNC with vnf data.
This DG calls a second called vnf-topology-preload-operation
This DG vnf-topology-assign includes a sequence of nodes that execute re=
spectively these actions:
1.Return failure if:
a)VF-module is already assigned
b)The VF-module does not exist in A&AI
2.Call vnf-topology-assign-vfmodule DG: this DG constructs=
a data structure called service-data to be stored in its internal DB and p=
otentially used to perform other actions
3.Establish relationships between vf-module and networks in A&AI (if th=
ere are networks specified in service data)
4.Update the vf-module orchestration status in A&AI (value =3D PendingC=
reate)
5.Update order status in service data in SDN-C
This DG begins with constructing service-data structure by concatenating= preload input and vnf-topology-operation input
Then the service-data is consolidated by information related to l3-netwo= rks (id, name, neutron network id, contrail network fqdn, ipv4/6 subnets)= p>
The DG logic:
For network in preload data
=E2=80=A2See if there is a network with the same role in the input vnf-topo=
logy-operation
=E2=86=92 YES, and this network exists in AAI =E2=86=92 Set these inf=
ormation in service-data
=E2=86=92 NO --> Use preload data to be set in service-data
The SO request towards SDN-C (POST /restconf/operations/VNF-API:vnf-topo= logy-operation) triggers the execution of a sequence of Directed graphs.
The main goals of this operation are:
=E2=80=A2Construct the service-data structure in the SDN-C
=E2=80=A2Establish relationship between VF-module and networks using servic=
e-data
=E2=80=A2Update the vf-module orchestration status in the inventory
=E2=80=A2Update the order status in service-data
In the vFWCL use-case, no networks were defined in the preload data or i= n vnf-topology-operation input
=E2=86=92 Communications with AAI are done through sdn-c aai-service plu=
gin
=E2=86=92 No relationships were established between vf-module and l3-networ=
ks in the vFWCL use-case.
4.Update vf-module orchestration-status i= n the inventory to assigned
5. Query SDNC for vf-module topology
In order to get vf-module topology, the SO requests SDNC via its control= ler adapter: GET /restconf/config/VNF-API:vnfs/vnf-list/be0ae48e-029a-4efc-= af46-d11bcf58c403
HTTP/1.1 200 OK Set-Cookie: JSESSIONID=3D1czkavx1g5yq715qw2lx7wcbfq;Path=3D/restconf Expires: Thu, 01 Jan 1970 00:00:00 GMT Set-Cookie: rememberMe=3DdeleteMe; Path=3D/restconf; Max-Age=3D0; Expires= =3DWed, 18-Jul-2018 14:53:16 GMT Content-Type: application/yang.data+xml Vary: Accept-Encoding, User-Agent Transfer-Encoding: chunked <?xml version=3D"1.0" encoding=3D"UTF-8"?> <vnf-list xmlns=3D"org:onap:sdnctl:vnf"> <vnf-id>be0ae48e-029a-4efc-af46-d11bcf58c403</vnf-id> <service-data> <vnf-request-information> <vnf-type>VspVfwsnk1607..base_vfw..module-0</vnf-type> <vnf-id>be0ae48e-029a-4efc-af46-d11bcf58c403</vnf-id> <generic-vnf-name>vfw-vf</generic-vnf-name> <use-preload>Y</use-preload> <generic-vnf-type>vfw_svc/vsp_vfwsnk_1607 0</generic-vnf-= type> <tenant>324b90de6e9a4ad88e93a100c2cedd5d</tenant> <vnf-name>vfw-vf-module</vnf-name> <aic-cloud-region>fr2</aic-cloud-region> <generic-vnf-id>e1a9ac1b-b9a0-4424-8659-69426c8bfdc8</gen= eric-vnf-id> </vnf-request-information> <vnf-topology-information> <vnf-parameters> <vnf-parameter-name>unprotected_private_net_id</vnf-pa= rameter-name> <vnf-parameter-value>unprotected_net</vnf-parameter-va= lue> </vnf-parameters> <vnf-parameters> <vnf-parameter-name>protected_private_net_id</vnf-para= meter-name> <vnf-parameter-value>protected_net</vnf-parameter-valu= e> </vnf-parameters> <vnf-parameters> <vnf-parameter-name>ext_private_net_id</vnf-parameter-= name> <vnf-parameter-value>external_net</vnf-parameter-value= > </vnf-parameters> <vnf-parameters> <vnf-parameter-name>protected_private_net_cidr</vnf-pa= rameter-name> <vnf-parameter-value>192.168.20.0/24</vnf-parameter-va= lue> </vnf-parameters> <vnf-parameters> <vnf-parameter-name>key_name</vnf-parameter-name> <vnf-parameter-value>vfw_key</vnf-parameter-value> </vnf-parameters> <vnf-parameters> <vnf-parameter-name>vfw_flavor_name</vnf-parameter-nam= e> <vnf-parameter-value>n2.cw.standard-1</vnf-parameter-v= alue> </vnf-parameters> <vnf-parameters> <vnf-parameter-name>cloud_env</vnf-parameter-name> <vnf-parameter-value>openstack</vnf-parameter-value>= ; </vnf-parameters> <vnf-parameters> <vnf-parameter-name>ext_private_net_cidr</vnf-paramete= r-name> <vnf-parameter-value>192.168.30.0/24</vnf-parameter-va= lue> </vnf-parameters> <vnf-parameters> <vnf-parameter-name>vsn_name_0</vnf-parameter-name> <vnf-parameter-value>vsn</vnf-parameter-value> </vnf-parameters> <vnf-parameters> <vnf-parameter-name>onap_private_net_id</vnf-parameter= -name> <vnf-parameter-value>oam_onap_tR3O</vnf-parameter-valu= e> </vnf-parameters> <vnf-parameters> <vnf-parameter-name>unprotected_private_subnet_id</vnf= -parameter-name> <vnf-parameter-value>unprotected_subnet</vnf-parameter= -value> </vnf-parameters> <vnf-parameters> <vnf-parameter-name>repo_url_artifacts</vnf-parameter-= name> <vnf-parameter-value>https://nexus.onap.org/content/repos= itories/releases</vnf-parameter-value> </vnf-parameters> <vnf-parameters> <vnf-parameter-name>vfw_name_0</vnf-parameter-name> <vnf-parameter-value>vfw-vf</vnf-parameter-value> </vnf-parameters> <vnf-parameters> <vnf-parameter-name>repo_url_blob</vnf-parameter-name&= gt; <vnf-parameter-value>https://nexus.onap.org/content/sites= /raw</vnf-parameter-value> </vnf-parameters> <vnf-parameters> <vnf-parameter-name>dcae_collector_port</vnf-parameter= -name> <vnf-parameter-value>8081</vnf-parameter-value> </vnf-parameters> <vnf-parameters> <vnf-parameter-name>public_net_id</vnf-parameter-name&= gt; <vnf-parameter-value>public</vnf-parameter-value> </vnf-parameters> <vnf-parameters> <vnf-parameter-name>vf_module_id</vnf-parameter-name&g= t; <vnf-parameter-value>vFirewallCL</vnf-parameter-value&= gt; </vnf-parameters> <vnf-parameters> <vnf-parameter-name>onap_private_net_cidr</vnf-paramet= er-name> <vnf-parameter-value>10.0.0.0/16</vnf-parameter-value&= gt; </vnf-parameters> <vnf-parameters> <vnf-parameter-name>vnf_id</vnf-parameter-name> <vnf-parameter-value>vFirewall_demo_app</vnf-parameter= -value> </vnf-parameters> <vnf-parameters> <vnf-parameter-name>vfw_image_name</vnf-parameter-name= > <vnf-parameter-value>Ubuntu 14.04</vnf-parameter-value= > </vnf-parameters> <vnf-parameters> <vnf-parameter-name>onap_private_subnet_id</vnf-parame= ter-name> <vnf-parameter-value>oam_onap_tR3O</vnf-parameter-valu= e> </vnf-parameters> <vnf-parameters> <vnf-parameter-name>install_script_version</vnf-parame= ter-name> <vnf-parameter-value>1.2.1</vnf-parameter-value> </vnf-parameters> <vnf-parameters> <vnf-parameter-name>vpg_private_ip_0</vnf-parameter-na= me> <vnf-parameter-value>192.168.10.200</vnf-parameter-val= ue> </vnf-parameters> <vnf-parameters> <vnf-parameter-name>vfw_private_ip_3</vnf-parameter-na= me> <vnf-parameter-value>192.168.30.101</vnf-parameter-val= ue> </vnf-parameters> <vnf-parameters> <vnf-parameter-name>vfw_private_ip_2</vnf-parameter-na= me> <vnf-parameter-value>10.0.100.1</vnf-parameter-value&g= t; </vnf-parameters> <vnf-parameters> <vnf-parameter-name>demo_artifacts_version</vnf-parame= ter-name> <vnf-parameter-value>1.2.1</vnf-parameter-value> </vnf-parameters> <vnf-parameters> <vnf-parameter-name>vfw_private_ip_1</vnf-parameter-na= me> <vnf-parameter-value>192.168.20.100</vnf-parameter-val= ue> </vnf-parameters> <vnf-parameters> <vnf-parameter-name>vfw_private_ip_0</vnf-parameter-na= me> <vnf-parameter-value>192.168.10.100</vnf-parameter-val= ue> </vnf-parameters> <vnf-parameters> <vnf-parameter-name>vsn_private_ip_2</vnf-parameter-na= me> <vnf-parameter-value>192.168.30.102</vnf-parameter-val= ue> </vnf-parameters> <vnf-parameters> <vnf-parameter-name>vsn_private_ip_1</vnf-parameter-na= me> <vnf-parameter-value>10.0.100.3</vnf-parameter-value&g= t; </vnf-parameters> <vnf-parameters> <vnf-parameter-name>vsn_private_ip_0</vnf-parameter-na= me> <vnf-parameter-value>192.168.20.250</vnf-parameter-val= ue> </vnf-parameters> <vnf-parameters> <vnf-parameter-name>pub_key</vnf-parameter-name> <vnf-parameter-value>ssh-rsa AAAAB3NzaC1yc2EAAAADAQABAAAB= AQDY15cdBmIs2XOpe4EiFCsaY6bmUmK/GysMoLl4UG51JCfJwvwoWCoA+6mDIbymZxhxq9IGxil= p/yTA6WQ9s/5pBag1cUMJmFuda9PjOkXl04jgqh5tR6I+GZ97AvCg93KAECis5ubSqw1xOCj4ut= fEUtPoF1OuzqM/lE5mY4N6VKXn+fT7pCD6cifBEs6JHhVNvs5OLLp/tO8Pa3kKYQOdyS0xc3rh+= t2lrzvKUSWGZbX+dLiFiEpjsUL3tDqzkEMNUn4pdv69OJuzWHCxRWPfdrY9Wg0j3mJesP29EBht= +w+EC9/kBKq+1VKdmsXUXAcjEvjovVL8l1BrX3BY0R8D</vnf-parameter-value> </vnf-parameters> <vnf-parameters> <vnf-parameter-name>ext_private_subnet_id</vnf-paramet= er-name> <vnf-parameter-value>external_subnet</vnf-parameter-va= lue> </vnf-parameters> <vnf-parameters> <vnf-parameter-name>dcae_collector_ip</vnf-parameter-n= ame> <vnf-parameter-value>84.39.39.157</vnf-parameter-value= > </vnf-parameters> <vnf-parameters> <vnf-parameter-name>protected_private_subnet_id</vnf-p= arameter-name> <vnf-parameter-value>protected_subnet</vnf-parameter-v= alue> </vnf-parameters> <vnf-parameters> <vnf-parameter-name>unprotected_private_net_cidr</vnf-= parameter-name> <vnf-parameter-value>192.168.10.0/24</vnf-parameter-va= lue> </vnf-parameters> <vnf-topology-identifier> <service-type>d39d0833-ea8a-45be-8863-76715697cdb3</se= rvice-type> <vnf-type>VspVfwsnk1607..base_vfw..module-0</vnf-type&= gt; <generic-vnf-name>vfw-vf</generic-vnf-name> <generic-vnf-type>vsp_vfwsnk_1607 0</generic-vnf-type&= gt; <vnf-name>vfw-vf-module</vnf-name> </vnf-topology-identifier> </vnf-topology-information> <service-information> <service-id>null</service-id> <service-type>null</service-type> <service-instance-id>d39d0833-ea8a-45be-8863-76715697cdb3<= ;/service-instance-id> <subscriber-name>notsurewecare</subscriber-name> </service-information> <vnf-id>be0ae48e-029a-4efc-af46-d11bcf58c403</vnf-id> <sdnc-request-header> <svc-notification-url>http://c1.vm1.mso.simpledemo.openecomp= .org:8080/adapters/rest/SDNCNotify</svc-notification-url> <svc-request-id>7b1b5758-d274-4305-aefc-289f1e614d7d-1532011= 988473</svc-request-id> <svc-action>assign</svc-action> </sdnc-request-header> <oper-status> <order-status>PendingCreate</order-status> </oper-status> <request-information> <request-action>VNFActivateRequest</request-action> <source>VID</source> <request-id>7b1b5758-d274-4305-aefc-289f1e614d7d</request= -id> </request-information> </service-data> <service-status> <final-indicator>Y</final-indicator> <request-status>synccomplete</request-status> <response-code>200</response-code> <vnfsdn-action>VNFActivateRequest</vnfsdn-action> <rpc-name>vnf-topology-operation</rpc-name> <rpc-action>assign</rpc-action> <response-timestamp>2018-07-19T14:53:09.027Z</response-times= tamp> </service-status> </vnf-list>
6. Call VNF adapter to create vf-module= p>
This step of the DoCreateVfModule subprocess corresponds to the allocati= on of the service related virtual resources and the deployment of the stack= s. In fact, the SO invokes the infrastrcuture orchestration services (Heat = in the case of Openstack-based infrastructure) via its VNF-adapters. The st= ack is created using heat template available in SO catalog.
7. Update AAI vf-module
8. Call SDNC adapter: Vf-module topology = activate
Same as the second step of this BPMN subprocess, this step corresponds t= o the execution of a set of Directed Graphs.
The SO HTTP Post request triggers the execution of vnf-topology-= operation DG
POST /restconf/operations/VNF-API:vnf-topology-operation HTTP/1.1 Accept: application/yang.data+xml Authorization: Basic YWRtaW46S3A4Yko0U1hzek0wV1hsaGFrM2VIbGNzZTJnQXc4NHZhb0= dHbUp2VXkyVQ=3D=3D Content-type: application/xml Cache-Control: no-cache Pragma: no-cache User-Agent: Java/1.8.0_171 Host: c1.vm1.sdnc.simpledemo.openecomp.org:8282 Connection: keep-alive Content-Length: 1272 <?xml version=3D"1.0" encoding=3D"UTF-8"?> <input xmlns=3D"org:onap:sdnctl:vnf"> <sdnc-request-header> <svc-request-id>7b1b5758-d274-4305-aefc-289f1e614d7d-1532012022= 299</svc-request-id> <svc-action>activate</svc-action> <svc-notification-url>http://c1.vm1.mso.simpledemo.openecomp.or= g:8080/adapters/rest/SDNCNotify</svc-notification-url> </sdnc-request-header> <request-information> <request-id>7b1b5758-d274-4305-aefc-289f1e614d7d</request-id= > <request-action>VNFActivateRequest</request-action> <source>VID</source> <notification-url /> </request-information> <service-information> <service-id>null</service-id> <service-type>null</service-type> <service-instance-id>d39d0833-ea8a-45be-8863-76715697cdb3</s= ervice-instance-id> <subscriber-name>notsurewecare</subscriber-name> </service-information> <vnf-request-information> <vnf-id>be0ae48e-029a-4efc-af46-d11bcf58c403</vnf-id> <vnf-type>VspVfwsnk1607..base_vfw..module-0</vnf-type> <vnf-name>vfw-vf-module</vnf-name> <generic-vnf-id>e1a9ac1b-b9a0-4424-8659-69426c8bfdc8</generi= c-vnf-id> <generic-vnf-name>vfw-vf</generic-vnf-name> <generic-vnf-type>vfw_svc/vsp_vfwsnk_1607 0</generic-vnf-typ= e> <aic-cloud-region>fr2</aic-cloud-region> <tenant>324b90de6e9a4ad88e93a100c2cedd5d</tenant> <use-preload>Y</use-preload> </vnf-request-information> </input>
Based on the POST request yang payload, (use-preload =3D Yes, svc-action= =3D activate):
vnf-topology-operation DG =E2=86=92 vnf-topology-preload-operati= on DG =E2=86=92 vnf-topology-activate DG.
This DG "vnf-topology-activate" includes a sequence of nodes that execut=
e the following actions:
1.Return failure if the vf-module is not assigned
2.Return failure if the order status is not PendingCreate or PendingUpdate<=
br>
3.Set last order status in service-data as with the actual value of order s=
tatus (PendingCreate or PendingUpdate)
4.Set order status in service-data as active
5.Set last action in service-data as VNFActivateRequest
6.Update the vf-module orchestration status in A&AI (value=3D act=
ive)
7.Set service-data with the actual vnf-topology-operation input
Finally, the VID Gets the orchestration status of the vf-module creation= operation
GET /ecomp/mso/infra/orchestrationRequests/v6/18c536e3-9208-46e5-8= c7f-131f9e645439 HTTP/1.1 Authorization: Basic SW5mcmFQb3J0YWxDbGllbnQ6cGFzc3dvcmQxJA=3D=3D X-FromAppId: VID X-ECOMP-RequestID: 1a14556b-0e01-49db-a6e4-e000505d6116 User-Agent: Jersey/2.23.1 (HttpUrlConnection 1.8.0_171) Cache-Control: no-cache Pragma: no-cache Host: vm1.mso.simpledemo.onap.org:8080 Accept: text/html, image/gif, image/jpeg, *; q=3D.2, */*; q=3D.2 Connection: keep-alive
HTTP/1.1 200 OK Expires: 0 Cache-Control: no-cache, no-store, must-revalidate X-Powered-By: Undertow/1 Server: WildFly/10 Pragma: no-cache Date: Thu, 19 Jul 2018 14:53:48 GMT Connection: keep-alive Content-Type: application/json Content-Length: 1863 {=20 "request":{=20 "requestId":"7b1b5758-d274-4305-aefc-28= 9f1e614d7d", "startTime":"Thu, 19 Jul = ;2018 14:53:08 GMT", "requestScope":"vfModule", "requestType":"createInstance", "requestDetails":{=20 "modelInfo":{=20 "mo= delCustomizationName":"VspVfwsnk1607..base_vfw..module-0", "mo= delInvariantId":"08fa9f0d-4fb5-41ae-8cc3-8282333ff6aa", "mo= delType":"vfModule", "mo= delName":"VspVfwsnk1607..base_vfw..module-0", "mo= delVersion":"2", "mo= delVersionId":"f8d43f3f-8189-4eac-a122-b5a5e06ad3ab", "mo= delCustomizationId":"bb084cb1-e8eb-4030-a2b7-931a3ae1c91f" }, "requestInfo":{=20 "so= urce":"VID", "in= stanceName":"vfw-vf-module", "su= ppressRollback":false, "re= questorId":"demo" }, "relatedInstanceList"= :[=20 {= =20 &nb= sp; "relatedInstance":{=20 &nb= sp; "instanceId":"d39d0833-ea8a-45be-8863-7671= 5697cdb3", &nb= sp; "modelInfo":{=20 &nb= sp; "modelInvariantId":"46c0= d35f-4a34-4f5b-9ee3-fd65f6f74ac2", &nb= sp; "modelType":"service", &nb= sp; "modelName":"vfw_svc", &nb= sp; "modelVersion":"2.0", &nb= sp; "modelVersionId":"84909c= 11-1a62-47b3-9aed-59c2ec5c891d" &nb= sp; } &nb= sp; } }, {= =20 &nb= sp; "relatedInstance":{=20 &nb= sp; "instanceId":"e1a9ac1b-b9a0-4424-8659-6942= 6c8bfdc8", &nb= sp; "modelInfo":{=20 &nb= sp; "modelCustomizationName"= :"vsp_vfwsnk_1607 0", &nb= sp; "modelInvariantId":"c758= 2c77-5a11-471c-a24f-5347ec811cdd", &nb= sp; "modelType":"vnf", &nb= sp; "modelName":"vsp_vfwsnk_= 1607", &nb= sp; "modelVersion":"2.0", &nb= sp; "modelVersionId":"db0fbb= 27-fd0d-40eb-8491-0f4a48adaefe", &nb= sp; "modelCustomizationId":"= 5365f464-3e2e-40be-9dc2-480c916bcf10" &nb= sp; } &nb= sp; } } ], "cloudConfiguration":= {=20 "te= nantId":"324b90de6e9a4ad88e93a100c2cedd5d", "lc= pCloudRegionId":"fr2" }, "requestParameters":{= =20 "us= ePreload":true } }, "instanceReferences":{=20 "serviceInstanceId":"= d39d0833-ea8a-45be-8863-76715697cdb3", "vnfInstanceId":"e1a9= ac1b-b9a0-4424-8659-69426c8bfdc8", "vfModuleInstanceId":= "be0ae48e-029a-4efc-af46-d11bcf58c403", "vfModuleInstanceName= ":"vfw-vf-module", "requestorId":"demo" }, "requestStatus":{=20 "requestState":"COMPL= ETE", "statusMessage":"Vf&n= bsp;Module has been created successfully.", "percentProgress":100= , "finishTime":"Thu,&nb= sp;19 Jul 2018 14:53:43 GMT" } } }
The vFW service deployment corresponds to three user operations on VID p= ortal. These user actions trigger respectively service, vnf node and vf-mod= ule instantiation by the SO.
Service and vnf instantiation corresponds to the creation of an object i= nstance in the inventory.
The vf-module creation invoques several ONAP components in order to crea= te the vf-module object instance in the inventory and deploy service virtua= lized resources in the infrastructure.
The SO BPMN processes invoked in the vFW deployment are generic and serv= ice creation is based on requests parameters. ( a la carte= )
The SDNC role in the vFW deployment is limited to the creation of servic= e related records (service-data) in the SDNC local data base. This is due t= o the vFW service itself because it doesn't include networks defined within= the service models.
|
|
---|
Before running the close loop, let's investigate what happens on the vfW= service side and how the vFW component interacts with DCAE.
The packet generator sends UDP packets to the sink through the vfirewall= . The sink shows in its graphs periodical traffic volumes:
Meanwhile, the vFW component includes a VES agent that reports measureme= nts to DCAE collector (VES or VNF Event Stream) on port 8081.
Example 1: High traffic ~ 1000 packets (100 packets x 10 streams)
POST /eventListener/v5 HTTP/1.1 Authorization: Basic Og=3D=3D User-Agent: libcurl-agent/1.0 Host: 84.39.39.157:8081 Accept: */* Content-type: application/json Content-Length: 1020 {=20 "event":{=20 "commonEventHeader":{=20 "domain":"measurement= sForVfScaling", "eventId":"TrafficSta= ts_1.2.3.4", "eventName":"vFirewal= lBroadcastPackets", "lastEpochMicrosec":1= 532032611090627, "priority":"Normal", "reportingEntityName"= :"fwll", "sequence":2012, "sourceName":"vfw-vf"= , "startEpochMicrosec":= 1532032600902328, "version":3, "eventType":"HTTP&nbs= p;request rate", "reportingEntityId":"= No UUID available", "sourceId":"4087b997-= db38-42c9-929b-10d223388159", "nfcNamingCode":"vVNF= ", "nfNamingCode":"vVNF" }, "measurementsForVfScalingFields":{=20 "measurementInterval"= :10, "cpuUsageArray":[=20 {= =20 &nb= sp; "cpuIdentifier":"cpu1", &nb= sp; "cpuIdle":100.000000, &nb= sp; "cpuUsageSystem":0.000000, &nb= sp; "cpuUsageUser":0.000000, &nb= sp; "percentUsage":0.000000 } ], "requestRate":9862, "vNicUsageArray":[=20 {= =20 &nb= sp; "receivedOctetsDelta":43731.000000, &nb= sp; "receivedTotalPacketsDelta":1016.000000, &nb= sp; "transmittedOctetsDelta":0.000000, &nb= sp; "transmittedTotalPacketsDelta":0.000000, &nb= sp; "valuesAreSuspect":"true", &nb= sp; "vNicIdentifier":"eth0" } ], "measurementsForVfSca= lingVersion":2.1 } } }
Another reported measurements
Example 2: Low traffic ~ 100 packets (100 packets x 1 stream)
POST /eventListener/v5 HTTP/1.1 Authorization: Basic Og=3D=3D User-Agent: libcurl-agent/1.0 Host: 84.39.39.157:8081 Accept: */* Content-type: application/json Content-Length: 1018 {=20 "event":{=20 "commonEventHeader":{=20 "domain":"measurement= sForVfScaling", "eventId":"TrafficSta= ts_1.2.3.4", "eventName":"vFirewal= lBroadcastPackets", "lastEpochMicrosec":1= 532032906557136, "priority":"Normal", "reportingEntityName"= :"fwll", "sequence":2041, "sourceName":"vfw-vf"= , "startEpochMicrosec":= 1532032896368945, "version":3, "eventType":"HTTP&nbs= p;request rate", "reportingEntityId":"= No UUID available", "sourceId":"4087b997-= db38-42c9-929b-10d223388159", "nfcNamingCode":"vVNF= ", "nfNamingCode":"vVNF" }, "measurementsForVfScalingFields":{=20 "measurementInterval"= :10, "cpuUsageArray":[=20 {= =20 &nb= sp; "cpuIdentifier":"cpu1", &nb= sp; "cpuIdle":100.000000, &nb= sp; "cpuUsageSystem":0.000000, &nb= sp; "cpuUsageUser":0.000000, &nb= sp; "percentUsage":0.000000 } ], "requestRate":9992, "vNicUsageArray":[=20 {= =20 &nb= sp; "receivedOctetsDelta":4343.000000, &nb= sp; "receivedTotalPacketsDelta":102.000000, &nb= sp; "transmittedOctetsDelta":0.000000, &nb= sp; "transmittedTotalPacketsDelta":0.000000, &nb= sp; "valuesAreSuspect":"true", &nb= sp; "vNicIdentifier":"eth0" } ], "measurementsForVfSca= lingVersion":2.1 } } }
VES agent measurements concern cpuUsage and vNicUsage of the vFW host.Me= asurement fields include "receivedTotalPacketsDelta" attribute that indicat= es the number of packets being forwarded from the packet generator to sink.= The close loop is based on the value of this metric.
When receiving measurements, the VES collector (located in the DCAE) pub= lishes these measurements on DMaap (Message router).
This published measurements matches with the example 1.
POST /events/unauthenticated.VES_MEASUREMENT_OUTPUT HTTP/1.1 Content-Type: application/cambria Accept: application/json Content-Length: 1001 Host: 10.0.11.1:3904 Connection: Keep-Alive User-Agent: Apache-HttpClient/4.5.3 (Java/1.8.0_162) Accept-Encoding: gzip,deflate 14.977.MyPartitionKey {=20 "event":{=20 "commonEventHeader":{=20 "startEpochMicrosec":= 1532032600902328, "sourceId":"4087b997-= db38-42c9-929b-10d223388159", "eventId":"TrafficSta= ts_1.2.3.4", "nfcNamingCode":"vVNF= ", "reportingEntityId":"= No UUID available", "internalHeaderFields= ":{=20 "co= llectorTimeStamp":"Thu, 07 19 2018 08:36:51 GMT" }, "eventType":"HTTP&nbs= p;request rate", "priority":"Normal", "version":3, "reportingEntityName"= :"fwll", "sequence":2012, "domain":"measurement= sForVfScaling", "lastEpochMicrosec":1= 532032611090627, "eventName":"vFirewal= lBroadcastPackets", "sourceName":"vfw-vf"= , "nfNamingCode":"vVNF" }, "measurementsForVfScalingFields":{=20 "cpuUsageArray":[=20 {= =20 &nb= sp; "percentUsage":0, &nb= sp; "cpuIdentifier":"cpu1", &nb= sp; "cpuIdle":100, &nb= sp; "cpuUsageSystem":0, &nb= sp; "cpuUsageUser":0 } ], "measurementInterval"= :10, "requestRate":9862, "vNicUsageArray":[=20 {= =20 &nb= sp; "transmittedOctetsDelta":0, &nb= sp; "receivedTotalPacketsDelta":1016, &nb= sp; "vNicIdentifier":"eth0", &nb= sp; "valuesAreSuspect":"true", &nb= sp; "transmittedTotalPacketsDelta":0, &nb= sp; "receivedOctetsDelta":43731 } ], "measurementsForVfSca= lingVersion":2.1 } } }
After performing correctly the closed loop steps for the vFW service, we= can investigate interactions between ONAP components. In fact, as we have = seen in the previous section, the DCAE VES collector sends measurements to = DMaap. Now, the TCA microservice gets measurements from DMaap in order to a= nalyse threshold crossing:
GET /events/unauthenticated.VES_MEASUREMENT_OUTPUT/OpenDCAE-c12/c1= 2-analytics-tca HTTP/1.1 Host: 10.0.11.1:3904 Connection: Keep-Alive User-Agent: Apache-HttpClient/4.5.5 (Java 1.5 minimum; Java/1.8.0_131) Accept-Encoding: gzip,deflate
A list of VES measurements is provided in response (The closed loop acti= on is not yet applied)
HTTP/1.1 200 OK Date: Thu, 19 Jul 2018 20:36:56 GMT Cache-Control: no-store, no-cache, must-revalidate Pragma: no-cache Expires: 0 Content-Type: application/json Accept-Encoding: gzip,deflate breadcrumbId: ID-7473fa227425-48456-1528796902051-0-11576860 User-Agent: Apache-HttpClient/4.5.5 (Java 1.5 minimum; Java/1.8.0_131) X-CSI-Internal-WriteableRequest: true Content-Length: 3253 Server: Jetty(9.2.z-SNAPSHOT) [=20 "{\"event\":{\"commonEventHeader\":{\"startEpochMicrosec\= ":1532032580526046,\"sourceId\":\"4087b997-db38-42c9-929b-10d223388159\",\"= eventId\":\"TrafficStats_1.2.3.4\",\"nfcNamingCode\":\"vVNF\",\"reportingEn= tityId\":\"No UUID available\",\"internalHeaderFields\":{\"collec= torTimeStamp\":\"Thu, 07 19 2018 08:36:30 GMT\"},\= "eventType\":\"HTTP request rate\",\"priority\":\"Normal\",\"vers= ion\":3,\"reportingEntityName\":\"fwll\",\"sequence\":2010,\"domain\":\"mea= surementsForVfScaling\",\"lastEpochMicrosec\":1532032590713867,\"eventName\= ":\"vFirewallBroadcastPackets\",\"sourceName\":\"vfw-vf\",\"nfNamingCode\":= \"vVNF\"},\"measurementsForVfScalingFields\":{\"cpuUsageArray\":[{\"percent= Usage\":0,\"cpuIdentifier\":\"cpu1\",\"cpuIdle\":100,\"cpuUsageSystem\":0,\= "cpuUsageUser\":0}],\"measurementInterval\":10,\"requestRate\":8001,\"vNicU= sageArray\":[{\"transmittedOctetsDelta\":0,\"receivedTotalPacketsDelta\":10= 20,\"vNicIdentifier\":\"eth0\",\"valuesAreSuspect\":\"true\",\"transmittedT= otalPacketsDelta\":0,\"receivedOctetsDelta\":43860}],\"measurementsForVfSca= lingVersion\":2.1}}}", "{\"event\":{\"commonEventHeader\":{\"startEpochMicrosec= \":1532032590713867,\"sourceId\":\"4087b997-db38-42c9-929b-10d223388159\",\= "eventId\":\"TrafficStats_1.2.3.4\",\"nfcNamingCode\":\"vVNF\",\"reportingE= ntityId\":\"No UUID available\",\"internalHeaderFields\":{\"colle= ctorTimeStamp\":\"Thu, 07 19 2018 08:36:40 GMT\"},= \"eventType\":\"HTTP request rate\",\"priority\":\"Normal\",\"ver= sion\":3,\"reportingEntityName\":\"fwll\",\"sequence\":2011,\"domain\":\"me= asurementsForVfScaling\",\"lastEpochMicrosec\":1532032600902328,\"eventName= \":\"vFirewallBroadcastPackets\",\"sourceName\":\"vfw-vf\",\"nfNamingCode\"= :\"vVNF\"},\"measurementsForVfScalingFields\":{\"cpuUsageArray\":[{\"percen= tUsage\":0,\"cpuIdentifier\":\"cpu1\",\"cpuIdle\":100,\"cpuUsageSystem\":0,= \"cpuUsageUser\":0}],\"measurementInterval\":10,\"requestRate\":7722,\"vNic= UsageArray\":[{\"transmittedOctetsDelta\":0,\"receivedTotalPacketsDelta\":1= 019,\"vNicIdentifier\":\"eth0\",\"valuesAreSuspect\":\"true\",\"transmitted= TotalPacketsDelta\":0,\"receivedOctetsDelta\":43645}],\"measurementsForVfSc= alingVersion\":2.1}}}", "{\"event\":{\"commonEventHeader\":{\"startEpochMicrosec= \":1532032600902328,\"sourceId\":\"4087b997-db38-42c9-929b-10d223388159\",\= "eventId\":\"TrafficStats_1.2.3.4\",\"nfcNamingCode\":\"vVNF\",\"reportingE= ntityId\":\"No UUID available\",\"internalHeaderFields\":{\"colle= ctorTimeStamp\":\"Thu, 07 19 2018 08:36:51 GMT\"},= \"eventType\":\"HTTP request rate\",\"priority\":\"Normal\",\"ver= sion\":3,\"reportingEntityName\":\"fwll\",\"sequence\":2012,\"domain\":\"me= asurementsForVfScaling\",\"lastEpochMicrosec\":1532032611090627,\"eventName= \":\"vFirewallBroadcastPackets\",\"sourceName\":\"vfw-vf\",\"nfNamingCode\"= :\"vVNF\"},\"measurementsForVfScalingFields\":{\"cpuUsageArray\":[{\"percen= tUsage\":0,\"cpuIdentifier\":\"cpu1\",\"cpuIdle\":100,\"cpuUsageSystem\":0,= \"cpuUsageUser\":0}],\"measurementInterval\":10,\"requestRate\":9862,\"vNic= UsageArray\":[{\"transmittedOctetsDelta\":0,\"receivedTotalPacketsDelta\":1= 016,\"vNicIdentifier\":\"eth0\",\"valuesAreSuspect\":\"true\",\"transmitted= TotalPacketsDelta\":0,\"receivedOctetsDelta\":43731}],\"measurementsForVfSc= alingVersion\":2.1}}}" ]
The last event in the previous response corresponds to VES measurements = published by the VES collector as shown in example 1.
Based on mesurements (vfw-vf in this case), TCA micro-service selects th= e appropriate configuration policy in order to analyse threshold crossing. = As receivedTotalPacketsDelta > 700, TCA gets vnf source data from the in= ventory, sets CL event status to ONSET and publishes alarm to DMaap with so= urce VNF data.
POST /events/unauthenticated.DCAE_CL_OUTPUT HTTP/1.1 Content-Length: 3511 Content-Type: application/json; charset=3DUTF-8 Host: 10.0.11.1:3904 Connection: Keep-Alive User-Agent: Apache-HttpClient/4.5.5 (Java 1.5 minimum; Java/1.8.0_131) Accept-Encoding: gzip,deflate [=20 {=20 "closedLoopAlarmStart":1532032580526046= , "closedLoopControlName":"ControlLoop-vF= irewall-d0a1dfc6-94f5-4fd4-a5b5-4630b438850a", "closedLoopEventClient":"DCAE_INSTANCE_= ID.dcae-tca", "closedLoopEventStatus":"ONSET", "from":"DCAE", "policyName":"DCAE.Config_tca-hi-lo", "policyScope":"DCAE", "policyVersion":"v0.0.1", "requestID":"79687ab1-ccf4-495a-b6dd-99= eb8d890608", "target":"generic-vnf.vnf-name", "version":"1.0.2", "AAI":{=20 "generic-vnf.vnf-name= ":"vfw-vf", "generic-vnf.vnf-id":= "e1a9ac1b-b9a0-4424-8659-69426c8bfdc8", "generic-vnf.vnf-type= ":"vfw_svc/vsp_vfwsnk_1607 0", "generic-vnf.service-= id":"8eba27fe-89eb-4c32-9ee6-aa5428c7d962", "generic-vnf.prov-sta= tus":"PROV", "generic-vnf.orchestr= ation-status":"Active", "generic-vnf.in-maint= ":false, "generic-vnf.is-close= d-loop-disabled":false, "generic-vnf.resource= -version":"1532012526533", "generic-vnf.model-in= variant-id":"c7582c77-5a11-471c-a24f-5347ec811cdd", "generic-vnf.model-ve= rsion-id":"db0fbb27-fd0d-40eb-8491-0f4a48adaefe", "generic-vnf.model-cu= stomization-id":"5365f464-3e2e-40be-9dc2-480c916bcf10", "generic-vnf.nf-type"= :"", "generic-vnf.nf-funct= ion":"", "generic-vnf.nf-role"= :"", "generic-vnf.nf-namin= g-code":"" }, "target_type":"VNF" }, {=20 "closedLoopAlarmStart":1532032590713867= , "closedLoopControlName":"ControlLoop-vF= irewall-d0a1dfc6-94f5-4fd4-a5b5-4630b438850a", "closedLoopEventClient":"DCAE_INSTANCE_= ID.dcae-tca", "closedLoopEventStatus":"ONSET", "from":"DCAE", "policyName":"DCAE.Config_tca-hi-lo", "policyScope":"DCAE", "policyVersion":"v0.0.1", "requestID":"79cf7e2d-a39b-41fc-abe4-e0= c58b79af8a", "target":"generic-vnf.vnf-name", "version":"1.0.2", "AAI":{=20 "generic-vnf.vnf-name= ":"vfw-vf", "generic-vnf.vnf-id":= "e1a9ac1b-b9a0-4424-8659-69426c8bfdc8", "generic-vnf.vnf-type= ":"vfw_svc/vsp_vfwsnk_1607 0", "generic-vnf.service-= id":"8eba27fe-89eb-4c32-9ee6-aa5428c7d962", "generic-vnf.prov-sta= tus":"PROV", "generic-vnf.orchestr= ation-status":"Active", "generic-vnf.in-maint= ":false, "generic-vnf.is-close= d-loop-disabled":false, "generic-vnf.resource= -version":"1532012526533", "generic-vnf.model-in= variant-id":"c7582c77-5a11-471c-a24f-5347ec811cdd", "generic-vnf.model-ve= rsion-id":"db0fbb27-fd0d-40eb-8491-0f4a48adaefe", "generic-vnf.model-cu= stomization-id":"5365f464-3e2e-40be-9dc2-480c916bcf10", "generic-vnf.nf-type"= :"", "generic-vnf.nf-funct= ion":"", "generic-vnf.nf-role"= :"", "generic-vnf.nf-namin= g-code":"" }, "target_type":"VNF" }, {=20 "closedLoopAlarmStart":1532032600902328= , "closedLoopControlName":"ControlLoop-vF= irewall-d0a1dfc6-94f5-4fd4-a5b5-4630b438850a", "closedLoopEventClient":"DCAE_INSTANCE_= ID.dcae-tca", "closedLoopEventStatus":"ONSET", "from":"DCAE", "policyName":"DCAE.Config_tca-hi-lo", "policyScope":"DCAE", "policyVersion":"v0.0.1", "requestID":"0460e743-bf88-40e0-9e49-c3= 56c903b0ce", "target":"generic-vnf.vnf-name", "version":"1.0.2", "AAI":{=20 "generic-vnf.vnf-name= ":"vfw-vf", "generic-vnf.vnf-id":= "e1a9ac1b-b9a0-4424-8659-69426c8bfdc8", "generic-vnf.vnf-type= ":"vfw_svc/vsp_vfwsnk_1607 0", "generic-vnf.service-= id":"8eba27fe-89eb-4c32-9ee6-aa5428c7d962", "generic-vnf.prov-sta= tus":"PROV", "generic-vnf.orchestr= ation-status":"Active", "generic-vnf.in-maint= ":false, "generic-vnf.is-close= d-loop-disabled":false, "generic-vnf.resource= -version":"1532012526533", "generic-vnf.model-in= variant-id":"c7582c77-5a11-471c-a24f-5347ec811cdd", "generic-vnf.model-ve= rsion-id":"db0fbb27-fd0d-40eb-8491-0f4a48adaefe", "generic-vnf.model-cu= stomization-id":"5365f464-3e2e-40be-9dc2-480c916bcf10", "generic-vnf.nf-type"= :"", "generic-vnf.nf-funct= ion":"", "generic-vnf.nf-role"= :"", "generic-vnf.nf-namin= g-code":"" }, "target_type":"VNF" } ]
The policy component requests DMaap in order to get published alarms: GE= T /events/unauthenticated.DCAE_CL_OUTPUT/dcae.policy.shared/drools?timeout= =3D15000&limit=3D100 HTTP/1.1
HTTP/1.1 200 OK Date: Thu, 19 Jul 2018 20:41:36 GMT Cache-Control: no-store, no-cache, must-revalidate Pragma: no-cache Expires: 0 Content-Type: application/json Accept: application/json Accept-Encoding: gzip,deflate breadcrumbId: ID-7473fa227425-48456-1528796902051-0-11578575 limit: 100 timeout: 15000 User-Agent: Apache-HttpClient/4.5.5 (Java/1.8.0_171) X-CSI-Internal-WriteableRequest: true Content-Length: 1281 Server: Jetty(9.2.z-SNAPSHOT) [ =20 "{\"closedLoopEventClient\":\"DCAE_INSTANCE_ID.dcae-tca\",\"policyVersio= n\":\"v0.0.1\",\"policyName\":\"DCAE.Config_tca-hi-lo\",\"policyScope\":\"D= CAE\",\"target_type\":\"VNF\",\"AAI\":{\"generic-vnf.resource-version\":\"1= 532012526533\",\"generic-vnf.nf-role\":\"\",\"generic-vnf.prov-status\":\"P= ROV\",\"generic-vnf.orchestration-status\":\"Active\",\"generic-vnf.is-clos= ed-loop-disabled\":false,\"generic-vnf.service-id\":\"8eba27fe-89eb-4c32-9e= e6-aa5428c7d962\",\"generic-vnf.in-maint\":false,\"generic-vnf.nf-type\":\"= \",\"generic-vnf.nf-naming-code\":\"\",\"generic-vnf.vnf-name\":\"vfw-vf\",= \"generic-vnf.model-version-id\":\"db0fbb27-fd0d-40eb-8491-0f4a48adaefe\",\= "generic-vnf.model-customization-id\":\"5365f464-3e2e-40be-9dc2-480c916bcf1= 0\",\"generic-vnf.nf-function\":\"\",\"generic-vnf.vnf-type\":\"vfw_svc/vsp= _vfwsnk_1607 0\",\"generic-vnf.model-invariant-id\":\"c7582c77-5a11-471c-a2= 4f-5347ec811cdd\",\"generic-vnf.vnf-id\":\"e1a9ac1b-b9a0-4424-8659-69426c8b= fdc8\"},\"closedLoopAlarmStart\":1532032875991084,\"closedLoopEventStatus\"= :\"ONSET\",\"closedLoopControlName\":\"ControlLoop-vFirewall-d0a1dfc6-94f5-= 4fd4-a5b5-4630b438850a\",\"version\":\"1.0.2\",\"target\":\"generic-vnf.vnf= -name\",\"requestID\":\"1a6f980d-4eed-432d-ba58-83bd34659f64\",\"from\":\"D= CAE\"}" ]
When detecting the published alarm, the policy begins to send notificati= ons to DMaap with different stages of policy processing (POLICY-CL-MGT topi= c).
It first acknowledges the onset alarm by sending an ACTIVE notification.=
POST /events/POLICY-CL-MGT HTTP/1.1 Content-Type: application/cambria Accept: application/json Content-Length: 1492 Host: vm1.mr.simpledemo.onap.org:3904 Connection: Keep-Alive User-Agent: Apache-HttpClient/4.5.5 (Java/1.8.0_171) Accept-Encoding: gzip,deflate 36.1447.9fb731ea-6449-4194-b0ae-618e50a87125{ "AAI": { "generic-vnf.resource-version": "1532012526533", "generic-vnf.nf-role": "", "generic-vnf.prov-status": "PROV", "generic-vnf.orchestration-status": "Active", "generic-vnf.is-closed-loop-disabled": "false", "generic-vnf.service-id": "8eba27fe-89eb-4c32-9ee6-aa5428c7d962", "generic-vnf.in-maint": "false", "generic-vnf.nf-type": "", "generic-vnf.nf-naming-code": "", "generic-vnf.vnf-name": "vfw-vf", "generic-vnf.model-version-id": "db0fbb27-fd0d-40eb-8491-0f4a48adaefe", "generic-vnf.model-customization-id": "5365f464-3e2e-40be-9dc2-480c916b= cf10", "generic-vnf.nf-function": "", "generic-vnf.vnf-type": "vfw_svc/vsp_vfwsnk_1607 0", "generic-vnf.model-invariant-id": "c7582c77-5a11-471c-a24f-5347ec811cdd= ", "generic-vnf.vnf-id": "e1a9ac1b-b9a0-4424-8659-69426c8bfdc8" }, "closedLoopAlarmStart": 1532032875991084, "closedLoopControlName": "ControlLoop-vFirewall-d0a1dfc6-94f5-4fd4-a5b5-4= 630b438850a", "version": "1.0.2", "requestId": "1a6f980d-4eed-432d-ba58-83bd34659f64", "closedLoopEventClient": "DCAE_INSTANCE_ID.dcae-tca", "targetType": "VNF", "target": "generic-vnf.vnf-name", "from": "pdp-0001-controller=3Dcontrolloop:amsterdam", "policyScope": "com", "policyName": "com.Config_BRMS_Param_BRMSParamvFirewall.EVENT", "policyVersion": "5", "notification": "ACTIVE", "notificationTime": "2018-07-19 20:41:46.486000+00:00", "history": [] }
In the previous notification, the onset is enriched with inventory data = of the vFWSNK vnf. The policy action does apply on this vnf. So, policy que= ries the inventory to get the targeted entity by the closed loop.
[Session org.onap.policy-engine.drools.amsterdam:policy-amsterdam-= rules:3.0.0:closedloop-amsterdam][OUT|AAI|https://aai.api.simpledemo.onap.o= rg:8443/aai/search/named-query|] { "query-parameters": { "named-query": { "named-query-uuid": "a93ac487-409c-4e8c-9e5f-334ae8f99087" } }, "instance-filters": { "instance-filter": [ { "generic-vnf": { "vnf-id": "e1a9ac1b-b9a0-4424-8659-69426c8bfdc8" } } ] } }
[Session org.onap.policy-engine.drools.amsterdam:policy-amsterdam-= rules:3.0.0:closedloop-amsterdam] [IN|AAI|https://aai.api.simpledemo.onap.org:8443/aai/search/named-query|] { =20 "inventory-response-item":[ =20 { =20 "model-name":"vsp_vfwsnk_1607", "generic-vnf":{ =20 "vnf-id":"e1a9ac1b-b9a0-4424-8659-69426c8bfdc8", "vnf-name":"vfw-vf", "vnf-type":"vfw_svc/vsp_vfwsnk_1607 0", "service-id":"8eba27fe-89eb-4c32-9ee6-aa5428c7d962", "prov-status":"PROV", "orchestration-status":"Active", "in-maint":false, "is-closed-loop-disabled":false, "resource-version":"1532012526533", "model-invariant-id":"c7582c77-5a11-471c-a24f-5347ec811cdd", "model-version-id":"db0fbb27-fd0d-40eb-8491-0f4a48adaefe", "model-customization-id":"5365f464-3e2e-40be-9dc2-480c916bcf10"= , "nf-type":"", "nf-function":"", "nf-role":"", "nf-naming-code":"" }, "extra-properties":{ =20 }, "inventory-response-items":{ =20 "inventory-response-item":[ =20 { =20 "model-name":"vfw_svc", "service-instance":{ =20 "service-instance-id":"d39d0833-ea8a-45be-8863-7671569= 7cdb3", "service-instance-name":"vfw_svc_1607", "environment-context":"General_Revenue-Bearing", "workload-context":"Production", "model-invariant-id":"46c0d35f-4a34-4f5b-9ee3-fd65f6f7= 4ac2", "model-version-id":"84909c11-1a62-47b3-9aed-59c2ec5c89= 1d", "resource-version":"1532011795844", "orchestration-status":"Active" }, "extra-properties":{ =20 }, "inventory-response-items":{ =20 "inventory-response-item":[ =20 { =20 "model-name":"vsp_vpg_1607", "generic-vnf":{ =20 "vnf-id":"be1c20fe-2646-45a1-b85d-80c4b00832a= 7", "vnf-name":"vpg-vf", "vnf-type":"vfw_svc/vsp_vpg_1607 0", "service-id":"8eba27fe-89eb-4c32-9ee6-aa5428c= 7d962", "prov-status":"PROV", "orchestration-status":"Active", "in-maint":false, "is-closed-loop-disabled":false, "resource-version":"1532012545029", "model-invariant-id":"bf2a3891-148d-442f-a136= -10782e48a418", "model-version-id":"89468b54-0e2c-4307-aac4-4= 661a53c0aac", "model-customization-id":"0ecc8cf9-19d8-41d7-= 9048-f22da4172d58", "nf-type":"", "nf-function":"", "nf-role":"", "nf-naming-code":"" }, "extra-properties":{ =20 } } ] } } ] } } ] }
The policy reacts to the published alarm by posting the CL operation to = DMaap:
POST /events/APPC-CL HTTP/1.1 Content-Type: application/cambria Accept: application/json Content-Length: 810 Host: vm1.mr.simpledemo.onap.org:3904 Connection: Keep-Alive User-Agent: Apache-HttpClient/4.5.5 (Java/1.8.0_171) Accept-Encoding: gzip,deflate 36.766.1cb70869-6a79-4d28-ba72-fe13cff1da14{ "CommonHeader": { "TimeStamp": 1532032906679, "APIver": "1.01", "RequestID": "1a6f980d-4eed-432d-ba58-83bd34659f64", "SubRequestID": "1", "RequestTrack": [], "Flags": [] }, "Action": "ModifyConfig", "Payload": { "generic-vnf.vnf-id": "be1c20fe-2646-45a1-b85d-80c4b00832a7", "pg-streams": { "pg-stream": [ { "id": "fw_udp1", "is-enabled": "true" }, { "id": "fw_udp2", "is-enabled": "true" }, { "id": "fw_udp3", "is-enabled": "true" }, { "id": "fw_udp4", "is-enabled": "true" }, { "id": "fw_udp5", "is-enabled": "true" } ] } } }
At this stage, the policy posts a set of notifications related to the op= eration processing (POLICY-CL-MGT topic). In fact, the policy engine querie= s the GUARD for the ability to apply the operation of the CL. If permitted,= it locks the target vnf (vPKG) so that no other similar operation could ta= rget the same vnf. It specifies also the actor responsible for performing t= he operation and the target vnf for the closed loop.
POST /events/POLICY-CL-MGT HTTP/1.1 Content-Type: application/cambria Accept: application/json Content-Length: 4765 Host: vm1.mr.simpledemo.onap.org:3904 Connection: Keep-Alive User-Agent: Apache-HttpClient/4.5.5 (Java/1.8.0_171) Accept-Encoding: gzip,deflate 36.1530.9fb731ea-6449-4194-b0ae-618e50a87125{ "AAI": { "generic-vnf.resource-version": "1532012526533", "generic-vnf.nf-role": "", "generic-vnf.prov-status": "PROV", "generic-vnf.orchestration-status": "Active", "generic-vnf.is-closed-loop-disabled": "false", "generic-vnf.service-id": "8eba27fe-89eb-4c32-9ee6-aa5428c7d962", "generic-vnf.in-maint": "false", "generic-vnf.nf-type": "", "generic-vnf.nf-naming-code": "", "generic-vnf.vnf-name": "vfw-vf", "generic-vnf.model-version-id": "db0fbb27-fd0d-40eb-8491-0f4a48adaefe", "generic-vnf.model-customization-id": "5365f464-3e2e-40be-9dc2-480c916b= cf10", "generic-vnf.nf-function": "", "generic-vnf.vnf-type": "vfw_svc/vsp_vfwsnk_1607 0", "generic-vnf.model-invariant-id": "c7582c77-5a11-471c-a24f-5347ec811cdd= ", "generic-vnf.vnf-id": "e1a9ac1b-b9a0-4424-8659-69426c8bfdc8" }, "closedLoopAlarmStart": 1532032875991084, "closedLoopControlName": "ControlLoop-vFirewall-d0a1dfc6-94f5-4fd4-a5b5-4= 630b438850a", "version": "1.0.2", "requestId": "1a6f980d-4eed-432d-ba58-83bd34659f64", "closedLoopEventClient": "DCAE_INSTANCE_ID.dcae-tca", "targetType": "VNF", "target": "generic-vnf.vnf-name", "from": "policy:amsterdam", "policyScope": "com", "policyName": "com.Config_BRMS_Param_BRMSParamvFirewall.EVENT.MANAGER.OPE= RATION.LOCKED.GUARD_NOT_YET_QUERIED", "policyVersion": "5", "notification": "OPERATION", "message": "Sending guard query for APPC ModifyConfig", "notificationTime": "2018-07-19 20:41:46.671000+00:00", "history": [] } 36.1495.9fb731ea-6449-4194-b0ae-618e50a87125{ "AAI": { "generic-vnf.resource-version": "1532012526533", "generic-vnf.nf-role": "", "generic-vnf.prov-status": "PROV", "generic-vnf.orchestration-status": "Active", "generic-vnf.is-closed-loop-disabled": "false", "generic-vnf.service-id": "8eba27fe-89eb-4c32-9ee6-aa5428c7d962", "generic-vnf.in-maint": "false", "generic-vnf.nf-type": "", "generic-vnf.nf-naming-code": "", "generic-vnf.vnf-name": "vfw-vf", "generic-vnf.model-version-id": "db0fbb27-fd0d-40eb-8491-0f4a48adaefe", "generic-vnf.model-customization-id": "5365f464-3e2e-40be-9dc2-480c916b= cf10", "generic-vnf.nf-function": "", "generic-vnf.vnf-type": "vfw_svc/vsp_vfwsnk_1607 0", "generic-vnf.model-invariant-id": "c7582c77-5a11-471c-a24f-5347ec811cdd= ", "generic-vnf.vnf-id": "e1a9ac1b-b9a0-4424-8659-69426c8bfdc8" }, "closedLoopAlarmStart": 1532032875991084, "closedLoopControlName": "ControlLoop-vFirewall-d0a1dfc6-94f5-4fd4-a5b5-4= 630b438850a", "version": "1.0.2", "requestId": "1a6f980d-4eed-432d-ba58-83bd34659f64", "closedLoopEventClient": "DCAE_INSTANCE_ID.dcae-tca", "targetType": "VNF", "target": "generic-vnf.vnf-name", "from": "policy:amsterdam", "policyScope": "com", "policyName": "com.Config_BRMS_Param_BRMSParamvFirewall.GUARD.RESPONSE", "policyVersion": "5", "notification": "OPERATION", "message": "Guard result for APPC ModifyConfig is Permit", "notificationTime": "2018-07-19 20:41:46.676000+00:00", "history": [] } 36.1605.9fb731ea-6449-4194-b0ae-618e50a87125{ "AAI": { "generic-vnf.resource-version": "1532012526533", "generic-vnf.nf-role": "", "generic-vnf.prov-status": "PROV", "generic-vnf.orchestration-status": "Active", "generic-vnf.is-closed-loop-disabled": "false", "generic-vnf.service-id": "8eba27fe-89eb-4c32-9ee6-aa5428c7d962", "generic-vnf.in-maint": "false", "generic-vnf.nf-type": "", "generic-vnf.nf-naming-code": "", "generic-vnf.vnf-name": "vfw-vf", "generic-vnf.model-version-id": "db0fbb27-fd0d-40eb-8491-0f4a48adaefe", "generic-vnf.model-customization-id": "5365f464-3e2e-40be-9dc2-480c916b= cf10", "generic-vnf.nf-function": "", "generic-vnf.vnf-type": "vfw_svc/vsp_vfwsnk_1607 0", "generic-vnf.model-invariant-id": "c7582c77-5a11-471c-a24f-5347ec811cdd= ", "generic-vnf.vnf-id": "e1a9ac1b-b9a0-4424-8659-69426c8bfdc8" }, "closedLoopAlarmStart": 1532032875991084, "closedLoopControlName": "ControlLoop-vFirewall-d0a1dfc6-94f5-4fd4-a5b5-4= 630b438850a", "version": "1.0.2", "requestId": "1a6f980d-4eed-432d-ba58-83bd34659f64", "closedLoopEventClient": "DCAE_INSTANCE_ID.dcae-tca", "targetType": "VNF", "target": "generic-vnf.vnf-name", "from": "policy:amsterdam", "policyScope": "com", "policyName": "com.Config_BRMS_Param_BRMSParamvFirewall.EVENT.MANAGER.OPE= RATION.LOCKED.GUARD_PERMITTED", "policyVersion": "5", "notification": "OPERATION", "message": "actor=3DAPPC,operation=3DModifyConfig,target=3DTarget [type= =3DVNF, resourceID=3Dbf2a3891-148d-442f-a136-10782e48a418],subRequestId=3D1= ", "notificationTime": "2018-07-19 20:41:46.679000+00:00", "history": [] }
The APPC indicates that operation is accepted through POST to DMaap (APP= C-CL topic):
POST /events/APPC-CL HTTP/1.1 Content-Type: application/cambria Content-Length: 643 Host: 10.0.11.1:3904 Connection: Keep-Alive User-Agent: Apache-HttpClient/4.5.3 (Java 1.5 minimum; Java/1.8.0_171) Accept-Encoding: gzip,deflate { =20 "Status":{ =20 "Value":"ACCEPTED", "Code":"100" }, "CommonHeader":{ =20 "OriginatorID":null, "SubrequestID":null, "RequestID":"1a6f980d-4eed-432d-ba58-83bd34659f64", "APIver":"1.01", "TimeStamp":"1532032906679" }, "Payload":{ =20 "generic-vnf.vnf-id":"be1c20fe-2646-45a1-b85d-80c4b00832a7", "pg-streams":"{\\\"pg-streams\\\": {\\\"pg-stream\\\":[{\\\"id\\\":\\= \"fw_udp1\\\", \\\"is-enabled\\\":\\\"true\\\"},{\\\"id\\\":\\\"fw_udp2\\\"= , \\\"is-enabled\\\":\\\"true\\\"},{\\\"id\\\":\\\"fw_udp3\\\", \\\"is-enab= led\\\":\\\"true\\\"},{\\\"id\\\":\\\"fw_udp4\\\", \\\"is-enabled\\\":\\\"t= rue\\\"},{\\\"id\\\":\\\"fw_udp5\\\", \\\"is-enabled\\\":\\\"true\\\"}]}}" } }
APPC applies the CL operation:
PUT /restconf/config/network-topology:network-topology/topology/to= pology-netconf/node/be1c20fe-2646-45a1-b85d-80c4b00832a7/yang-ext:mount/sam= ple-plugin:sample-plugin/pg-streams/ HTTP/1.1 Content-type: application/json Content-Length: 221 Host: 10.0.2.1:8282 Connection: Keep-Alive User-Agent: Apache-HttpClient/4.5.3 (Java/1.8.0_171) Accept-Encoding: gzip,deflate Authorization: Basic YWRtaW46YWRtaW4=3D {"pg-streams": {"pg-stream":[{"id":"fw_udp1", "is-enabled":"true"},{"id":"f= w_udp2", "is-enabled":"true"},{"id":"fw_udp3", "is-enabled":"true"},{"id":"= fw_udp4", "is-enabled":"true"},{"id":"fw_udp5", "is-enabled":"true"}]}}
This operation corresponds to the execution of the latest action (Modify= Config) of topology-operation-all Directed Graph
APPC publishes the status of the operation:
POST /events/APPC-CL HTTP/1.1 Content-Type: application/cambria Content-Length: 642 Host: 10.0.11.1:3904 Connection: Keep-Alive User-Agent: Apache-HttpClient/4.5.3 (Java 1.5 minimum; Java/1.8.0_171) Accept-Encoding: gzip,deflate 0.636.{ =20 "Status":{ =20 "Value":"SUCCESS", "Code":"400" }, "CommonHeader":{ =20 "OriginatorID":null, "SubrequestID":null, "RequestID":"1a6f980d-4eed-432d-ba58-83bd34659f64", "APIver":"1.01", "TimeStamp":"1532032906679" }, "Payload":{ =20 "generic-vnf.vnf-id":"be1c20fe-2646-45a1-b85d-80c4b00832a7", "pg-streams":"{\\\"pg-streams\\\": {\\\"pg-stream\\\":[{\\\"id\\\":\\= \"fw_udp1\\\", \\\"is-enabled\\\":\\\"true\\\"},{\\\"id\\\":\\\"fw_udp2\\\"= , \\\"is-enabled\\\":\\\"true\\\"},{\\\"id\\\":\\\"fw_udp3\\\", \\\"is-enab= led\\\":\\\"true\\\"},{\\\"id\\\":\\\"fw_udp4\\\", \\\"is-enabled\\\":\\\"t= rue\\\"},{\\\"id\\\":\\\"fw_udp5\\\", \\\"is-enabled\\\":\\\"true\\\"}]}}" } }
Policy gets the last events published on APPC-CL topic: GET /events/APPC= -CL/e14c7c74-be39-492f-b3f4-26b0a0748155/drools?timeout=3D15000&limit= =3D100 HTTP/1.1
HTTP/1.1 200 OK Date: Thu, 19 Jul 2018 20:41:47 GMT Cache-Control: no-store, no-cache, must-revalidate Pragma: no-cache Expires: 0 Content-Type: application/json Accept: application/json Accept-Encoding: gzip,deflate breadcrumbId: ID-7473fa227425-48456-1528796902051-0-11578639 limit: 100 timeout: 15000 User-Agent: Apache-HttpClient/4.5.5 (Java/1.8.0_171) X-CSI-Internal-WriteableRequest: true Content-Length: 854 Server: Jetty(9.2.z-SNAPSHOT) [ =20 "{\"Status\":{\"Value\":\"SUCCESS\",\"Code\":\"400\"},\"CommonHeader\":{= \"OriginatorID\":null,\"SubrequestID\":null,\"RequestID\":\"1a6f980d-4eed-4= 32d-ba58-83bd34659f64\",\"APIver\":\"1.01\",\"TimeStamp\":\"1532032906679\"= },\"Payload\":{\"generic-vnf.vnf-id\":\"be1c20fe-2646-45a1-b85d-80c4b00832a= 7\",\"pg-streams\":\"{\\\\\\\"pg-streams\\\\\\\": {\\\\\\\"pg-stream\\\\\\\= ":[{\\\\\\\"id\\\\\\\":\\\\\\\"fw_udp1\\\\\\\", \\\\\\\"is-enabled\\\\\\\":= \\\\\\\"true\\\\\\\"},{\\\\\\\"id\\\\\\\":\\\\\\\"fw_udp2\\\\\\\", \\\\\\\"= is-enabled\\\\\\\":\\\\\\\"true\\\\\\\"},{\\\\\\\"id\\\\\\\":\\\\\\\"fw_udp= 3\\\\\\\", \\\\\\\"is-enabled\\\\\\\":\\\\\\\"true\\\\\\\"},{\\\\\\\"id\\\\= \\\":\\\\\\\"fw_udp4\\\\\\\", \\\\\\\"is-enabled\\\\\\\":\\\\\\\"true\\\\\\= \"},{\\\\\\\"id\\\\\\\":\\\\\\\"fw_udp5\\\\\\\", \\\\\\\"is-enabled\\\\\\\"= :\\\\\\\"true\\\\\\\"}]}}\"}}" ]
Policy publishes notifications that indicate the final status of the ope= ration
POST /events/POLICY-CL-MGT HTTP/1.1 Content-Type: application/cambria Accept: application/json Content-Length: 3592 Host: vm1.mr.simpledemo.onap.org:3904 Connection: Keep-Alive User-Agent: Apache-HttpClient/4.5.5 (Java/1.8.0_171) Accept-Encoding: gzip,deflate 36.1647.9fb731ea-6449-4194-b0ae-618e50a87125{ "AAI": { "generic-vnf.resource-version": "1532012526533", "generic-vnf.nf-role": "", "generic-vnf.prov-status": "PROV", "generic-vnf.orchestration-status": "Active", "generic-vnf.is-closed-loop-disabled": "false", "generic-vnf.service-id": "8eba27fe-89eb-4c32-9ee6-aa5428c7d962", "generic-vnf.in-maint": "false", "generic-vnf.nf-type": "", "generic-vnf.nf-naming-code": "", "generic-vnf.vnf-name": "vfw-vf", "generic-vnf.model-version-id": "db0fbb27-fd0d-40eb-8491-0f4a48adaefe", "generic-vnf.model-customization-id": "5365f464-3e2e-40be-9dc2-480c916b= cf10", "generic-vnf.nf-function": "", "generic-vnf.vnf-type": "vfw_svc/vsp_vfwsnk_1607 0", "generic-vnf.model-invariant-id": "c7582c77-5a11-471c-a24f-5347ec811cdd= ", "generic-vnf.vnf-id": "e1a9ac1b-b9a0-4424-8659-69426c8bfdc8" }, "closedLoopAlarmStart": 1532032875991084, "closedLoopControlName": "ControlLoop-vFirewall-d0a1dfc6-94f5-4fd4-a5b5-4= 630b438850a", "version": "1.0.2", "requestId": "1a6f980d-4eed-432d-ba58-83bd34659f64", "closedLoopEventClient": "DCAE_INSTANCE_ID.dcae-tca", "targetType": "VNF", "target": "generic-vnf.vnf-name", "from": "policy:amsterdam", "policyScope": "com", "policyName": "com.Config_BRMS_Param_BRMSParamvFirewall.APPC.RESPONSE", "policyVersion": "5", "notification": "OPERATION: SUCCESS", "message": "actor=3DAPPC,operation=3DModifyConfig,target=3DTarget [type= =3DVNF, resourceID=3Dbf2a3891-148d-442f-a136-10782e48a418],start=3D2018-07-= 19T20:41:46.678Z,end=3Dnull,subRequestId=3D1,outcome=3Dnull,message=3Dnull"= , "notificationTime": "2018-07-19 20:41:47.032000+00:00", "history": [] } 36.1855.9fb731ea-6449-4194-b0ae-618e50a87125{ "AAI": { "generic-vnf.resource-version": "1532012526533", "generic-vnf.nf-role": "", "generic-vnf.prov-status": "PROV", "generic-vnf.orchestration-status": "Active", "generic-vnf.is-closed-loop-disabled": "false", "generic-vnf.service-id": "8eba27fe-89eb-4c32-9ee6-aa5428c7d962", "generic-vnf.in-maint": "false", "generic-vnf.nf-type": "", "generic-vnf.nf-naming-code": "", "generic-vnf.vnf-name": "vfw-vf", "generic-vnf.model-version-id": "db0fbb27-fd0d-40eb-8491-0f4a48adaefe", "generic-vnf.model-customization-id": "5365f464-3e2e-40be-9dc2-480c916b= cf10", "generic-vnf.nf-function": "", "generic-vnf.vnf-type": "vfw_svc/vsp_vfwsnk_1607 0", "generic-vnf.model-invariant-id": "c7582c77-5a11-471c-a24f-5347ec811cdd= ", "generic-vnf.vnf-id": "e1a9ac1b-b9a0-4424-8659-69426c8bfdc8" }, "closedLoopAlarmStart": 1532032875991084, "closedLoopControlName": "ControlLoop-vFirewall-d0a1dfc6-94f5-4fd4-a5b5-4= 630b438850a", "version": "1.0.2", "requestId": "1a6f980d-4eed-432d-ba58-83bd34659f64", "closedLoopEventClient": "DCAE_INSTANCE_ID.dcae-tca", "targetType": "VNF", "target": "generic-vnf.vnf-name", "from": "policy:amsterdam", "policyScope": "com", "policyName": "com.Config_BRMS_Param_BRMSParamvFirewall.EVENT.MANAGER", "policyVersion": "5", "notification": "FINAL: SUCCESS", "message": "Exception in processing closed loop", "notificationTime": "2018-07-19 20:41:47.036000+00:00", "history": [ { "actor": "APPC", "operation": "ModifyConfig", "target": "Target [type=3DVNF, resourceID=3Dbf2a3891-148d-442f-a136-1= 0782e48a418]", "start": 1532032906678, "end": 1532032907035, "subRequestId": "1", "outcome": "Failure_Exception", "message": "current operation is not null (an operation is already ru= nning)" } ] }
At this stage, we can check sink graphs to see if traffic volume has bee= n regulated:
The vFW closed loop is based on VES (VNF Event Stream) reported measurem= ents that TCA analyses and publishes related alams to DMaap. The policy has= the responsibility for triggering ModifyConfig action that APPC executes o= n the target vnf (vPKG). All closed loop interactions are relying on the Me= ssage router (DMaap) by publishing topics and subscribing to them.
The policy component has the biggest responsibility in this mechanism. I= t takes decision for applying CL actions, requests the inventory for the ta= rget vnf and selects CL actor, and follows the execution of the action by p= osting CL operation notification.
On the APPC side, the CL the action corresponds to the exection of a Dir= ected graph.