Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

Triggered by merges in policy/pap (Stretch)

Test Case Id

Description

Pre-conditions

Test Steps

Expected Results

1

Perform healthcheck for the 2nd generation PAP engine

  • Policy PAP docker image available

API – healthcheck

Method - GET

Endpoint: http://<host>:8081/health(?)

The PAP should return health status as “true”






Triggered by merges in policy/api (Stretch)

Test Case Id

Description

Pre-conditions

Test Steps

Expected Results

1

Perform healthcheck for the Policy Lifecycle API

  • Policy API docker image available

API – healthcheck

Method - GET

Endpoint: http://<host>:8081/health(?)

The API should return health status as “true”

...







Code Block
titlevFirewall - TCA Configuration Policy Payload
linenumberstrue
collapsetrue
tca_policy: "{
  "domain": "measurementsForVfScaling",
  "metricsPerEventName": [
    {
      "eventName": "vFirewallBroadcastPackets",
      "controlLoopSchemaType": "VNF",
      "policyScope": "DCAE",
      "policyName": "DCAE.Config_tca-hi-lo",
      "policyVersion": "v0.0.1",
 
      "thresholds": [
        {
          "closedLoopControlName": "ControlLoop-vFirewall-d0a1dfc6-94f5-4fd4-a5b5-4630b438850a",
          "version": "1.0.2",
          "fieldPath": "$.event.measurementsForVfScalingFields.vNicUsageArray[*].receivedTotalPacketsDelta",
          "thresholdValue": 300,
          "direction": "LESS_OR_EQUAL",
          "severity": "MAJOR",
          "closedLoopEventStatus": "ONSET"
        },
        {
          "closedLoopControlName": "ControlLoop-vFirewall-d0a1dfc6-94f5-4fd4-a5b5-4630b438850a",
          "version": "1.0.2",
          "fieldPath": "$.event.measurementsForVfScalingFields.vNicUsageArray[*].receivedTotalPacketsDelta",
          "thresholdValue": 700,
          "direction": "GREATER_OR_EQUAL",
          "severity": "CRITICAL",
          "closedLoopEventStatus": "ONSET"
        }
      ]
    }
  ]
 
}"
Code Block
titlevFirewall - Operational Policy
linenumberstrue
collapsetrue
controlLoop:
  version: 2.0.0
  controlLoopName: ControlLoop-vFirewall-d0a1dfc6-94f5-4fd4-a5b5-4630b438850a
  trigger_policy: unique-policy-id-1-modifyConfig
  timeout: 1200
  abatement: false

policies:
  - id: unique-policy-id-1-modifyConfig
    name: modify packet gen config
    description:
    actor: APPC
    recipe: ModifyConfig
    target:
      # TBD - Cannot be known until instantiation is done
      resourceID: Eace933104d443b496b8.nodes.heat.vpg
	  type: VNF	
    retry: 0
    timeout: 300
    success: final_success
    failure: final_failure
    failure_timeout: final_failure_timeout
    failure_retries: final_failure_retries
    failure_exception: final_failure_exception
    failure_guard: final_failure_guard

Code Block
titleDCAE Control Loop Event (TCA) - vFirewall
linenumberstrue
collapsetrue
{
	"closedLoopEventClient": "DCAE_INSTANCE_ID.dcae-tca",
	"policyVersion": "1.0.0.5",
	"policyName": "vFirewall",
	"policyScope": "resource=SampleResource,service=SampleService,type=SampleType,closedLoopControlName=SampleClosedLoop",
	"target_type": "VNF",
	"AAI": {
		"generic-vnf.vnf-name": "zdfw1fwl01fwl02"
	},
	"closedLoopAlarmStart": 1484855291527925,
	"closedLoopEventStatus": "ONSET",
	"closedLoopControlName": "ControlLoop-vFirewall-d0a1dfc6-94f5-4fd4-a5b5-4630b438850a",
	"version": "1.0.2",
	"target": "generic-vnf.vnf-name",
	"requestID": "8c1b8bd8-06f7-493f-8ed7-daaa4cc481bc",
	"from": "DCAE"
}
Code Block
titleAAI vnf-name query
linenumberstrue
collapsetrue
https://{aai}/aai/v11/network/generic-vnfs/generic-vnf?vnf-name=zdfw1fwl01fwl02
Code Block
titleAAI named-query response
linenumberstrue
collapsetrue
For a different vnfName 
{
    "vnf-id": "4e46ad6c-cebe-4460-858e-b5806883271b",
    "vnf-name": "vfw7f5a57d6",
    "vnf-type": "da818f33-97e1-4edf-98a5/5759f208-b75c-4b35-9599 0",
    "service-id": "a322c144-537c-4532-bf1b-0a4889083388",
    "prov-status": "PREPROV",
    "orchestration-status": "Created",
    "in-maint": false,
    "is-closed-loop-disabled": false,
    "resource-version": "1521467089262",
    "model-invariant-id": "a1efbbdd-2077-4b86-9fc0-244af99760f0",
    "model-version-id": "34c3221b-1326-4f35-9ed7-6f2f7e59d788",
    "model-customization-id": "1798c9a9-eaae-438f-bac3-b013599e8909",
    "nf-type": "",
    "nf-function": "",
    "nf-role": "",
    "nf-naming-code": "",
    "relationship-list": {
        "relationship": [
            {
                "related-to": "service-instance",
                "related-link": "/aai/v11/business/customers/customer/DemoCust_7d454ef5-f5ea-4346-b2d3-e9797f5a57d6/service-subscriptions/service-subscription/vFW/service-instances/service-instance/7c45e4f7-aa7a-4130-9ee3-c5c1d81840df",
                "relationship-data": [
                    {
                        "relationship-key": "customer.global-customer-id",
                        "relationship-value": "DemoCust_7d454ef5-f5ea-4346-b2d3-e9797f5a57d6"
                    },
                    {
                        "relationship-key": "service-subscription.service-type",
                        "relationship-value": "vFW"
                    },
                    {
                        "relationship-key": "service-instance.service-instance-id",
                        "relationship-value": "7c45e4f7-aa7a-4130-9ee3-c5c1d81840df"
                    }
                ],
                "related-to-property": [
                    {
                        "property-key": "service-instance.service-instance-name",
                        "property-value": "Service_Ete_Name7d454ef5-f5ea-4346-b2d3-e9797f5a57d6"
                    }
                ]
            },
            {
                "related-to": "vserver",
                "related-link": "/aai/v11/cloud-infrastructure/cloud-regions/cloud-region/CloudOwner/RegionOne/tenants/tenant/50b190410b2a4c229d8a6044a80ab7c1/vservers/vserver/3f3f3c72-269d-45e6-8953-692424f2df1f",
                "relationship-data": [
                    {
                        "relationship-key": "cloud-region.cloud-owner",
                        "relationship-value": "CloudOwner"
                    },
                    {
                        "relationship-key": "cloud-region.cloud-region-id",
                        "relationship-value": "RegionOne"
                    },
                    {
                        "relationship-key": "tenant.tenant-id",
                        "relationship-value": "50b190410b2a4c229d8a6044a80ab7c1"
                    },
                    {
                        "relationship-key": "vserver.vserver-id",
                        "relationship-value": "3f3f3c72-269d-45e6-8953-692424f2df1f"
                    }
                ],
                "related-to-property": [
                    {
                        "property-key": "vserver.vserver-name",
                        "property-value": "demofwl01pgn"
                    }
                ]
            },
            {
                "related-to": "vserver",
                "related-link": "/aai/v11/cloud-infrastructure/cloud-regions/cloud-region/CloudOwner/RegionOne/tenants/tenant/50b190410b2a4c229d8a6044a80ab7c1/vservers/vserver/4c45d0a4-a873-4d95-87ca-2a198322c9c4",
                "relationship-data": [
                    {
                        "relationship-key": "cloud-region.cloud-owner",
                        "relationship-value": "CloudOwner"
                    },
                    {
                        "relationship-key": "cloud-region.cloud-region-id",
                        "relationship-value": "RegionOne"
                    },
                    {
                        "relationship-key": "tenant.tenant-id",
                        "relationship-value": "50b190410b2a4c229d8a6044a80ab7c1"
                    },
                    {
                        "relationship-key": "vserver.vserver-id",
                        "relationship-value": "4c45d0a4-a873-4d95-87ca-2a198322c9c4"
                    }
                ],
                "related-to-property": [
                    {
                        "property-key": "vserver.vserver-name",
                        "property-value": "demofwl01snk"
                    }
                ]
            },
            {
                "related-to": "vserver",
                "related-link": "/aai/v11/cloud-infrastructure/cloud-regions/cloud-region/CloudOwner/RegionOne/tenants/tenant/50b190410b2a4c229d8a6044a80ab7c1/vservers/vserver/b96416ef-fc4e-49cb-8120-1d56686d2e90",
                "relationship-data": [
                    {
                        "relationship-key": "cloud-region.cloud-owner",
                        "relationship-value": "CloudOwner"
                    },
                    {
                        "relationship-key": "cloud-region.cloud-region-id",
                        "relationship-value": "RegionOne"
                    },
                    {
                        "relationship-key": "tenant.tenant-id",
                        "relationship-value": "50b190410b2a4c229d8a6044a80ab7c1"
                    },
                    {
                        "relationship-key": "vserver.vserver-id",
                        "relationship-value": "b96416ef-fc4e-49cb-8120-1d56686d2e90"
                    }
                ],
                "related-to-property": [
                    {
                        "property-key": "vserver.vserver-name",
                        "property-value": "vfw7f5a57d6"
                    }
                ]
            }
        ]
    }
}
Code Block
titleAPPC request
linenumberstrue
collapsetrue
{
  	"CommonHeader": {
  		  "TimeStamp": 1500997725298,
  		  "APIver": "1.01",
  		  "RequestID": "664be3d2-6c12-4f4b-a3e7-c349acced200",
  		  "RequestTrack": [],
  		  "Flags": []
  	},
  	"Action": "ModifyConfig",
  	"Payload": {
    	"generic-vnf.vnf-id": "fw0001vm001fw001",
    	"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"
        	}]
    	}
  	}
}


Code Block
titleAPPC response
linenumberstrue
collapsetrue
ACCEPT response

{
    "Status": {
        "Value": "ACCEPTED",
        "Code": "100"
    },
    "Payload": {
        "pg-streams": "{\\\"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\\\"}]}}",
        "generic-vnf.vnf-id": "fw0001vm001fw001"
    },
    "CommonHeader": {
        "TimeStamp": "1493841850199",
        "APIver": "1.01",
        "RequestID": "664be3d2-6c12-4f4b-a3e7-c349acced200",
        "SubrequestID": null,
        "OriginatorID": null
    }
}


SUCCESS response



{
    "Status": {
        "Value": "SUCCESS",
        "Code": "400"
    },
    "Payload": {
        "pg-streams": "{\\\"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\\\"}]}}",
        "generic-vnf.vnf-id": "fw0001vm001fw001"
    },
    "CommonHeader": {
        "TimeStamp": "1493841850199",
        "APIver": "1.01",
        "RequestID": "664be3d2-6c12-4f4b-a3e7-c349acced200",
        "SubrequestID": null,
        "OriginatorID": null
    }
}

VOLTE Use Case


Code Block
titleVOLTE - Operational Policy
linenumberstrue
collapsetrue
controlLoop:
  version: 2.0.0
  controlLoopName: ControlLoop-VOLTE-2179b738-fd36-4843-a71a-a8c24c70c55b
  trigger_policy: unique-policy-id-1-restart
  timeout: 3600
  abatement: false

policies:
  - id: unique-policy-id-1-restart
    name: Restart the VM
    description:
    actor: VFC
    recipe: Restart
    target:
      type: VM
    retry: 3
    timeout: 1200
    success: final_success
    failure: final_failure
    failure_timeout: final_failure_timeout
    failure_retries: final_failure_retries
    failure_exception: final_failure_exception
    failure_guard: final_failure_guard

...