Versions Compared

Key

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

...

Section
bordertrue
Column
width60%
Code Block
languagejs
themeEclipse
titleExtensible HPA Hyper-Threading Policy ExampleTemplate for the HPA policies
linenumberstrue
collapsetrue
{
    "service": "hpaHyperThreadingPolicy{the model name of a policy}",
    "policyName": "oofBeijing.hyperThreadingPolicy_vGMuxInfra{policy scope folder}.{policy name; must be unique}",
    "description": "Hyper threading{description of a policy}",
for vGMuxInfra",   "templateVersion": "0.0.1{policy model version}",
    "version": "oofBeijing{policy version}",
    "priority": "3",
  "riskType": "test{priority in 1-10; larger the number higher the priority is}",
    "riskType": "{the type of risk}",
    "riskLevel": "2{the level of risk}",
    "guard": "{True/False flag to indicate whether guard is applicable or not}",
    "content": { 
      "hyperThreadingPropertiesresource": [ "{resource name}",
      {"attributeidentity": "cpuCores{policy identity}",
      "valuepolicyScope": ["4", "operator": ">=", "unit": ""}{a tag representing policy scope}"],
      {"attributepolicyType": "cpuCores{policy type}",
"value": "10",      "operatorflavorFeatures": "<=", "unit": ""},[
        {"attribute": "cpuThreads", "value": "2", "operator
          "flavorLabel": ">{VM/VFC id}",
"unit": ""},       {"attribute": "cpuThreadsPolicy", "valueflavorProperties":[
"dedicated", "operator": "=", "unit": ""},            {"attribute": "cpuSockets", "values": ["2", "4", "6"], "operator": "any", "unit": ""},
	  {"attribute": "memory", "value": 8, "operator": ">", "unit": "GB"}
    ],
              "hpa-feature" : "{HPA feature type}",
              "mandatory" : "{mandatoriness of the feature}",
              "identityscore" : "hyperThreading_vGMuxInfra",{priority of this feature if the feature is not mandatory for VM}"
    "policyScope": ["vCPE", "US", "INTERNATIONAL", "ip", "vGMuxInfra"],     "typearchitecture": "hpaHyperThreadingPolicy{supported architecuture}",
    "resourceInstanceType          "hpa-version": ["vGMuxInfra"]"{version for hpa capability}",
             }
}
Column
width45%
Expand
titleComments and Notes: HPA Hyper-Threading Policy Example
  • Underlying model to generate this policy example is extensible
    and can be used to generate other HPA policies.
  • The value domain of the operator field is <, <=, >, >=, =, !=,
    any, all, many where any represents one from a set,
    all represents all the values of a set, and many represents more
    than one from a set.
  • The model can capture simple expressions. This example captures;
    4<=cpuCores<=10, cpuThreads>2, cpuThreadsPolicy=dedicated,
    cpuSockets is one from {2, 4, 6}, memory>8GB, etc.
  • Instead of modeling policy scope over multiple explicite dimentions,
    it is modeled as a list of tags/strings to achieve extensiblity and
    support model-agnostic getConfig query
     "hpa-feature-attributes": [
                    {
                      "hpa-attribute-key": "{attribute name}", 
                      "hpa-attribute-value": "{attribute value}",
                      "operator": "{comparison operator}", 
                      "unit": "{the unit of an attribute}"}
                  ]
                }
              ] 
            }
          ]
        }
    }
    Column
    width45%
    Expand
    titleComments and Notes: HPA CPU Topology Policy Example

    Template for the HPA policies.

    Section
    bordertrue
    Column
    width60%
    Code Block
    languagejs
    themeEclipse
    titleHPA Hyper-Threading Policy Example
    linenumberstrue
    collapsetrue
    {
        "service": "hpaHyperThreadingPolicyhpaPolicy",
        "policyName": "oofBeijing.hyperThreadingPolicyhpaPolicy_vGMuxInfra",
        "description": "Hyper threadingHPA policy for vGMuxInfra",
        "templateVersion": "0.0.1",
        "version": "oofBeijing1.0",
        "priority": "3",
        "riskType": "test",
        "riskLevel": "2",
        "guard": "False",
        "content": { 
          "hyperThreadingPropertiesresources": {"vGMuxInfra",
          "cpuCoresidentity": { "value": 4hpaPolicy_vGMuxInfra",
    "operator": "="},
          "cpuThreadspolicyScope": {["vCPE", "valueUS":, 2"INTERNATIONAL", "operatorip":, "=vGMuxInfra"}],
          "cpuThreadsPolicy": { "value"policyType": "dedicatedhpaPolicy",
    "operator      "flavorFeatures": [
    "="},       "cpuSockets": {
    "value": 2, "operator": "="}
        },     "identityflavorLabel": "hyperThreading_vGMuxInfraflavor_label_vm_01",
    
       "policyScope": {       "serviceTypeflavorProperties": ["vCPE"],[
                {
                  "geoRegionhpa-feature" : ["UScpuTopology", "INTERNATIONAL"],
                  "networkTypemandatory" : ["ipTrue"],
          "resourceInstanceType        "architecture": ["vGMuxInfra"]generic",
             },     "typehpa-version": "hpaHyperThreadingPolicyv1",
        "resourceInstanceType          "hpa-feature-attributes": ["vGMuxInfra"]
      }
    }
    Column
    width45%
    Expand
    titleComments and Notes: HPA Hyper-Threading Policy Example

    The fields in this example policy are typically generated from a TOSCA service model specified by VNF vendors or service designers. This policy cannot be changed during the life-cycle of a service.

    Section
    bordertrue
    Column
    width60%
    Code Block
    languagejs
    themeEclipse
    titleDistance Policy Example
    linenumberstrue
    collapsetrue
    {
      "service": "distancePolicy",
      "policyName": "oofBeijing.distancePolicy_vGMuxInfra",
      "description": "Distance Policy for vGMuxInfra",
      "templateVersion": "0.0.1",
      "version": "oofBeijing",
      "priority": "3",
      "riskType": "test",
      "riskLevel": "2",
      "guard": "False",
      "content": {
        "distanceProperties": {              {"hpa-attribute-key":"numCpuSockets", "hpa-attribute-value": "2","operator": ">=", "unit": ""},
                    {"hpa-attribute-key":"numCpuSockets", "hpa-attribute-value": "4","operator": "<=", "unit": ""},
                    {"locationInfohpa-attribute-key": {"numCpuCores", "hpa-attribute-value": "customer_location2", "operator":">=", "unit": "="},
          "distance": { "          {"hpa-attribute-key":"numCpuCores", "hpa-attribute-value": "5004", "operator": "<=", "unit": "km" },
          "resourceInstanceType": { "value": "vGMuxInfra", "operator": "="},     },
        "identity{"hpa-attribute-key":"numCpuThreads", "hpa-attribute-value": "4", "operator":">=", "unit": "distance-vGMuxInfra"},
            "policyScope": {       {"serviceTypehpa-attribute-key": ["vCPEnumCpuThreads"],       "geoRegion"hpa-attribute-value": ["US8", "INTERNATIONAL"],
          "networkType"operator":"<=", "unit": ["ip"],}
          "resourceInstanceType": ["vGMuxInfra"]       ]
                },
                {
                  "typehpa-feature" : "distancePolicybasicCapabilities",
        }
    }
    Column
    width45%
    Expand
    titleComments and Notes: Distance Policy

    The fields in this example policy are typically generated from a TOSCA service model specified by VNF vendors or service designers. However, the policy can be updated over time by operators.

    Section
    bordertrue
    Column
    width60%
    Code Block
    languagejs
    themeEclipse
    titleHPA AES Policy Example
    linenumberstrue
    collapsetrue
    {          "mandatory" : "True",
                  "servicearchitecture": "hpaAesPolicygeneric",
        "policyName          "hpa-version": "oofBeijing.aesPolicy_vGMuxInfrav1",
        "description": "AES policy for vGMuxInfra",          "templateVersionhpa-feature-attributes": "0.0.1",[
        "version": "oofBeijing",     "priority": "3",     {"riskTypehpa-attribute-key": "testnumVirtualCpu",
        "riskLevel"hpa-attribute-value": "26",     "guardoperator": "False=",    "unit": "content":},
     {         "aesProperties": { 	    	"version{"hpa-attribute-key": { "valuesvirtualMemSize": 1.0, "operatorhpa-attribute-value": "=6"}, 	    	"hwArch": { "values""operator": "intel_64=", "operatorunit": "=GB"},
     	    	"aesFeature": {"values": "true","operator": "="}      ]
      },         "identity": "aes_vGMuxInfra", },
               "policyScope": {
    			"serviceType": ["vCPE"],             "geoRegionhpa-feature" : ["USovsDpdk",
    "INTERNATIONAL"],              "networkTypemandatory" : ["ipFalse"],
                  "resourceInstanceTypescore" : ["vGMuxInfra"]3",
                  },"architecture": "generic",
              "type    "hpa-version": "hpaAesPolicyv1",
               "resourceInstanceType   "hpa-feature-attributes": ["vGMuxInfra"]
                    }
    }
    Column
    width45%
    Expand
    titleComments and Notes: HPA AES Policy

    The fields in this example policy are typically generated from a TOSCA service model specified by VNF vendors or service designers. This policy cannot be changed during the life-cycle of a service.

    Section
    bordertrue
    Column
    width60%
    Code Block
    languagejs
    themeEclipse
    titleHPA OCS_DPDK Policy Example
    linenumberstrue
    collapsetrue
    {
        "service": "hpaOvsDpdkPolicy",
        "policyName": "oofBeijing.hpaOvsDpdkPolicy_vGMuxInfra",
        "description": "HPA OVS DPDK policy for vGMuxInfra",
        "templateVersion": "0.0.1",
        "version": "oofBeijing",
        "priority": "3",
        "riskType": "test",
        "riskLevel": "2",
        "guard": "False {"hpa-attribute-key":"dataProcessingAccelerationLibrary", "hpa-attribute-value":"ovsDpdk_version", "operator": "=", "unit":""}
                  ]
                },
                {
                  "hpa-feature" : "cpuInstructionSetExtensions",
        "content": {         "ovsDpdkPropertiesmandatory" : {"True",
    	    	"version": { "values": 1.0, "operator        "architecture": "=INTEL-64"},
                "hwArch": { "valueshpa-version": "*v1", "operator": "="},
    	
               	"OvsDpdk": {"values": "true", "operatorhpa-feature-attributes": "="}[
            },         "identity{"hpa-attribute-key": "ovsDpdk_vGMuxInfrainstructionSetExtensions",         "policyScope": {
      "hpa-attribute-value":["<CPUINST>", "<CPUINST>"] "operator": "ALL", "unit":""}
             "serviceType": ["vCPE"],     ]
           "geoRegion": ["US", "INTERNATIONAL"],   }
             "networkType": ["ip"], 
            },
      "resourceInstanceType": ["vGMuxInfra"]       {
     },         "typeflavorLabel": "hpaOvsDpdkPolicyflavor_label_vm_02",
              "resourceInstanceTypeflavorProperties": ["vGMuxInfra"][
              }
    }
    Column
    width45%
    Expand
    titleComments and Notes: HPA OVS_DPDK Policy

    The fields in this example policy are typically generated from a TOSCA service model specified by VNF vendors or service designers. This policy cannot be changed during the life-cycle of a service.

    Section
    bordertrue
    Column
    width60%
    Code Block
    languagejs
    themeEclipse
    titleHPA CPU_Pinning Policy Example
    linenumberstrue
    collapsetrue
    {  {
         "service": "hpaCpuPinningPolicy",     "policyName"   "hpa-feature" : "oofBeijing.hpaCpuPinningPolicy_vGMuxInfracpuPinningy",
        "description": "CPU Pinning policy for vGMuxInfra",     "templateVersionmandatory" : "0.0.1True",
            "version": "oofBeijing",     "priorityarchitecture": "3generic",
        "riskType": "test",          "riskLevelhpa-version": "2v1",
        "guard": "False",          "contenthpa-feature-attributes": [
    {         "cpuPinningProperties": { 	    	"pinning": { "valueshpa-attribute-key":"logicalCpuThreadPinningPolicy", "prefer"hpa-attribute-value":"<CPUTHREADPOLICY>", "operator": "=", "unit":""},
            },        {"hpa-attribute-key":"logicalCpuPinningPolicy", "identityhpa-attribute-value": "cpuPinning_vGMuxInfra<CPUPOLICY>","operator": "=", "unit":""},
          "policyScope": {       ]
         "serviceType": ["vCPE"],      },
          "geoRegion": ["US", "INTERNATIONAL"],    {
            "networkType"      "hpa-feature" : ["ipbasicCapabilities"],
                  "resourceInstanceTypemandatory" : ["vGMuxInfra"]True",
                  },"architecture": "generic",
              "type    "hpa-version": "hpaCpuPinningv1",
            "resourceInstanceType      "hpa-feature-attributes": ["vGMuxInfra"]
                   }
    }
    Column
    width45%
    Expand
    titleComments and Notes: HPA CPU_Pinning Policy

    The fields in this example policy are typically generated from a TOSCA service model specified by VNF vendors or service designers. This policy cannot be changed during the life-cycle of a service.

    Section
    bordertrue
    Column
    width60%
    Code Block
    languagejs
    themeEclipse
    titleHPA NUMA Policy Example
    linenumberstrue
    collapsetrue
    {
        "service": "hpaNumaPolicy",
        "policyName": "oofBeijing.hpaNumaPolicy_vGMuxInfra",
        "description": "Hyper NUMA policy for vGMuxInfra",
        "templateVersion": "0.0.1",
        "version": "oofBeijing",
        "priority": "3",]
        "riskType": "test",
        "riskLevel": "2",
        "guard": "False",
        "content": {
            "numaProperties": {
    	    	"version": { "values": 1.0, "operator": "="} {"hpa-attribute-key": "numVirtualCpu", "hpa-attribute-value": "6", "operator": "=", "unit": ""},
                    {"hpa-attribute-key": "virtualMemSize", "hpa-attribute-value":"6", "operator": "=", "unit": "GB"}
                  ]
                },
                {
                  "hpa-feature" : "localStorage",
                "hwArch": { "valuesmandatory" : "*False",
                  "operatorscore" : "=5"},
    			"numaNodes": { "values": 2, "operator
                  "architecture": "=generic"},
    			"complexAttributes": [
    				{
    					"numaCpu": { "values": [0, 1], "operator              "hpa-version": "=v1"},
    					"numaMem": { "values": 2, "operator,
                  "hpa-feature-attributes": [
                    {"hpa-attribute-key": "=diskSize", "unithpa-attribute-value": "GB"},
    				},
    				{
    					"numaCpu": { "values": [2, 3, 4, 5], "operator": "="},
    					"numaMem": { "values": 42", "operator": "=", "unit": "GB"},   
          	        {"hpa-attribute-key": "ephemeralDiskSize", "hpa-attribute-value": "2", "operator": "=", "unit": "GB"},
    		               {"hpa-attribute-key": "swapMemSize", "hpa-attribute-value":"16", "operator": "=", "unit": "MB"},
          } 	    	]   ]
         },       },
     "identity": "numa_vGMuxInfra",         "policyScope": {
                  "serviceTypehpa-feature" : ["vCPEpcie"],
                  "geoRegionmandatory" : ["USTrue",
     "INTERNATIONAL"],             "networkTypearchitecture": ["ipgeneric"],
                  "resourceInstanceTypehpa-version": ["vGMuxInfra"]
      v1",
         },         "typehpa-feature-attributes": "hpaNumaPolicy", [
                    {"resourceInstanceTypehpa-attribute-key": ["vGMuxInfrapciCount"]
        }
    }
    Column
    width45%
    Expand
    titleComments and Notes: HPA NUMA Policy

    The fields in this example policy are typically generated from a TOSCA service model specified by VNF vendors or service designers. This policy cannot be changed during the life-cycle of a service.

    Section
    bordertrue
    Column
    width60%
    Code Block
    languagejs
    themeEclipse
    titleHPA SGX Policy Example
    linenumberstrue
    collapsetrue
    {
        "service": "hpaSgxPolicy",
        "policyName": "oofBeijing.hpaSgxPolicy_vGMuxInfra",
        "description": "SGX policy for vGMuxInfra",
        "templateVersion": "0.0.1",
        "version": "oofBeijing",
        "priority": "3",
        "riskType": "test",
        "riskLevel": "2",
        "guard": "False",
        "content": {, "hpa-attribute-value": "2", "operator": "=", "unit": ""},
                    {"hpa-attribute-key": "pciVendorId", "hpa-attribute-value":"8086", "operator": "=", "unit": ""},
    	            {"hpa-attribute-key": "pciDeviceId", "hpa-attribute-value": "2", "operator": "=", "unit": ""} 
                 "sgxProperties": { 	    	"version{"hpa-attribute-key": { "valuesfunctionType": 1.0, "operatorhpa-attribute-value": "=<PCITYPEVALUE>"},
    			"hwArchoperator": { "values": "intel_64""=", "operatorunit": "="},
    			"sgxMemSize": { "values": "128", "operator": "=", "unit": "MB"}, 
                  ]
           "sgxPubkeyHash": { "values": "octect_string", "operator": "="}
             }, ] 
          "identity": "sgx_vGMuxInfra"  },
            "policyScope": {
     
              "serviceTypeflavorLabel": ["vCPE"],
     "flavor_label_vm_03",
              "geoRegionflavorProperties": ["US", "INTERNATIONAL"],[
                {
                  "networkTypehpa-feature" : ["ipnuma"],
                  "resourceInstanceTypemandatory" : ["vGMuxInfraFalse"]
     ,
          },         "typescore" : "hpaSgxPolicy5",
            "resourceInstanceType      "architecture": ["vGMuxInfra"]generic",
           }
    }
    Column
    width45%
    Expand
    titleComments and Notes: HPA SGX Policy

    The fields in this example policy are typically generated from a TOSCA service model specified by VNF vendors or service designers. This policy cannot be changed during the life-cycle of a service.

    Section
    bordertrue
    Column
    width60%
    Code Block
    languagejs
    themeEclipse
    titleAffinity Policy Example
    linenumberstrue
    collapsetrue
    {       "servicehpa-version": "affinityPolicyv1",
        "policyName": "oofBeijing.affinityPolicy_vcpe",          "descriptionhpa-feature-attributes": "Affinity policy for vCPE",[
        "templateVersion": "1702.03",     "version": "oofBeijing",     {"priorityhpa-attribute-key": "5numaNodes",     "riskType"hpa-attribute-value": "test2",
        "riskLeveloperator": "2=",
        "guardunit": "False"},
        "content": {            {"identityhpa-attribute-key": "affinity_vCPEnumaCpu-0", "hpa-attribute-value":"2", "operator": "=", "unit": ""},
       "policyScope": {             "serviceType{"hpa-attribute-key": ["vCPEnumaMem-0"],             "geoRegion"hpa-attribute-value": "2048", "operator": ["US=", "INTERNATIONAL"],"unit": "MB"}
                    {"networkTypehpa-attribute-key": ["ipnumaCpu-1"],
                "resourceInstanceType, "hpa-attribute-value":"4", "operator": ["vGMuxInfra=", "vGunit"]: ""},
           },         {"affinityPropertyhpa-attribute-key": {
                "qualifier": {"numaMem-1", "value": "different4096", "operator": "=", "},unit": "MB"}
                  "category": {"value": "complex", "operator": "="}]
                },
            "type"    {
                  "hpa-feature" : "affinityPolicybasicCapabilities",
                  "resourceInstanceTypemandatory" : ["vGMuxInfraTrue",
       "vG"]           "architecture": "generic",
                 }
    }
    Column
    width45%
    Expand
    titleComments and Notes: Affinity Policy

    The fields in this example policy are typically generated from a TOSCA service model specified by VNF vendors or service designers. This policy cannot be changed during the life-cycle of a service.

    Section
    bordertrue
    border
    Column
    width60%
    Code Block
    languagejs
    themeEclipse
    titleCapacity Policy Example
    linenumberstrue
    collapsetrue
    { "hpa-version": "v1",
            "service": "capacityPolicy",     "policyNamehpa-feature-attributes": "oofBeijing.capacityPolicy_vGMuxInfra",[
         "description": "Capacity policy for vGMuxInfra",           {"templateVersionhpa-attribute-key": "1702.03numVirtualCpu", "hpa-attribute-value": "6", "operator": "=", "versionunit": "oofBeijing"},
        "priority            {"hpa-attribute-key": "5virtualMemSize",
        "riskTypehpa-attribute-value": "test6",     "riskLeveloperator": "2=",
        "guardunit": "FalseGB",}
        "content": {         "identity": "capacity_vGMuxInfra",]
                "policyScope": {},
                {
    "serviceType": ["VCPE"],             "geoRegionhpa-feature" : ["UShugePages",
     "INTERNATIONAL"],             "networkTypemandatory" : ["ipFalse"],
                  "resourceInstanceTypescore" : ["vGMuxInfra7"],
            },       "architecture":  "capacityPropertygeneric":,
     {             "cpuhpa-version": {"valuev1": 2,
    "operator": ">"},             "memoryhpa-feature-attributes": {" [
                     {"hpa-attribute-key": "memoryPageSize", "hpa-attribute-value": 4"<MEMORYPAGESIZE>", "operator": ">=", "unit": "Gb"}
            },      ]
                }
              ] 
      "type": "capacityPolicy",      }
         "resourceInstanceType": ["vGMuxInfra"]
        }
    }
    
    Column
    width45%
    Expand
    titleComments and Notes: Capacity HPA CPU Topology Policy Example

    The fields in this example policy are typically generated from a TOSCA service model specified by VNF vendors or service designers. This policy cannot be changed during the life-cycle of a service.

    Section



    CPUTHREADPOLICY = prefer, isolate, require

    CPUPOLICY = shared, dedicated

    PCIETYPEVALUE: SRIOV, PCI-PASSTHROUGH

    CPUINST = aes, avx, sha_ni, mpx, adcx, mpx, pclmulqdq, rdrand,sse, etc

    MEMORYPAGESIZE = 4KB (unit=KB), 2MB (unit=MB), 1GB(unit=GB), ANY, Other explicit Page size

    Section
    bordertrue
    Column
    width60%
    Code Block
    languagejs
    themeEclipse
    titleMin Guarantee Distance Policy Example
    linenumberstrue
    collapsetrue
    {
        "service": "minGuaranteePolicydistancePolicy",
        "policyName": "oofBeijing.minGuaraneedistancePolicy_vGMuxInfra",
     
      "description": "MinDistance guarantee policyPolicy for vGMuxInfra",
    
       "templateVersion": "17020.0.031",
        ""version": "oofBeijing",
        "priority": "53",
        "riskType": "test",
     
      "riskLevel": "2",
     
      "guard": "False",
     
      "content": {
        "distanceProperties": {
          "identitylocationInfo": "minGuaranteecustomer_vGMuxInfralocation",
            "policyScopedistance": { "value":            "serviceType"500", "operator": ["vCPE<"], "unit": "km" }
        },
        "geoRegionresources": ["USvGMuxInfra", "INTERNATIONALvG"],
        "applicableResources": "any",
          "networkTypeidentity": ["ipdistance-vGMuxInfra"],
           
        "resourceInstanceTypepolicyScope": ["vGMuxInfra"]
            },
            "minGuaranteeProperty": {
                "cpu": {"value": "true", "operator": "="},
           vCPE", "US", "INTERNATIONAL", "ip", "vGMuxInfra"],
        "memorypolicyType": {"valuedistancePolicy":
    "false", "operator": "="}
            },
            "type": "minGuaraneePolicy",
            "resourceInstanceType": ["vGMuxInfra"]
        }
    }
    Column
    width
    }
    Column
    width45%
    Expand
    titleComments and Notes: Min Guarantee Distance Policy

    The fields in this example policy are typically generated from a TOSCA service model specified by VNF vendors or service designers. This However, the policy cannot be changed during the life-cycle of a servicecan be updated over time by operators.

    Section
    bordertrue
    Column
    width60%
    Code Block
    languagejs
    themeEclipse
    titleOptimization HPA Basic Capabilities Policy Example
    linenumberstrue
    collapsetrue
    {
        "servicehpa-feature" : "PlacementOptimizationPolicybasicCapabilities",
        "policyNamemandatory" : "oofBeijing.PlacementOptimizationPolicy_vGMuxInfraFalse",
        "descriptionscore" : "Placement Optimization Policy for vGMuxInfra5",
        "templateVersionarchitecture": "1702.03generic",
        "hpa-version": "oofBeijingv1",
        "priorityhpa-feature-attributes": "5", [
           {"riskTypehpa-attribute-key": "testnumVirtualCpu",     "riskLevel"hpa-attribute-value": "36",     "guardoperator": "False=",     "contentunit": {""},
            "objectiveParameter{"hpa-attribute-key": {
                "parameterAttributes": [
                    {
                        "resource": ["vGMuxInfra"],
                        "customerLocationInfo": "customer_loc","virtualMemSize", "hpa-attribute-value":"6", "operator": "=", "unit": "GB"}
                        "parameter": "distance]
    }
    Column
    width45%
    Expand
    titleComments and Notes: HPA Basic Capabilities Policy

    The fields in this example policy are typically generated from a TOSCA service model specified by VNF vendors or service designers. This policy cannot be changed during the life-cycle of a service.

    Section
    bordertrue
    Column
    width60%
    Code Block
    languagejs
    themeEclipse
    titleHPA OVS DPDK Policy Example
    linenumberstrue
    collapsetrue
    {
        "hpa-feature" : "ovsDpdk",
        "mandatory" : "False",
         "score" : "5",
         "weightarchitecture": "1INTEL-64",
        "hpa-version": "v1",
        "hpa-feature-attributes": [
          {"hpa-attribute-key":"dataProcessingAccelerationLibrary", "hpa-attribute-value":"ovsDpdk_version", "operator": "product="=
    , "unit":""}
                   },
                    {
                        "resource": ["vG"],
                  ]
    }
    Column
    width45%
    Expand
    titleComments and Notes: HPA OVS DPDK Policy

    The fields in this example policy are typically generated from a TOSCA service model specified by VNF vendors or service designers. This policy cannot be changed during the life-cycle of a service.

    For this policy others architectures are also applicable.

    Section
    bordertrue
    Column
    width60%
    Code Block
    languagejs
    themeEclipse
    titleHPA CPU Pinning Policy Example
    linenumberstrue
    collapsetrue
    {
       "hpa-feature" : "cpuPinning",
       "mandatory" : "False",
       "score" : "5",
       "architecture": "generic",
       "hpa-version": "v1",
       "hpa-feature-attributes": [
         {"hpa-attribute-key":"logicalCpuThreadPinningPolicy", "hpa-attribute-value":"<CPUTHREADPOLICY>", "operator": "=", "unit":""},
         {"customerLocationInfohpa-attribute-key": "customer_loclogicalCpuPinningPolicy",                     "parameter"hpa-attribute-value": "distance<CPUPOLICY>",
                        "weight"operator": "1=",                     "operator": "product"
                    }
           "unit":""},
        ],
                "operator": "sum"
            },
            "identity": "optimization
    }
    Column
    width45%
    Expand
    titleComments and Notes: HPA CPU Pinning Policy

    The fields in this example policy are typically generated from a TOSCA service model specified by VNF vendors or service designers. This policy cannot be changed during the life-cycle of a service.


    CPUTHREADPOLICY = prefer, isolate, require
    CPUPOLICY = shared, dedicated


    Section
    bordertrue
    Column
    width60%
    Code Block
    languagejs
    themeEclipse
    titleHPA NUMA Policy Example
    linenumberstrue
    collapsetrue
    {
        "hpa-feature" : "numa",
        "mandatory"   : "policyScopeFalse":,
    {    "score"    : "5",
        "serviceTypearchitecture": ["vCPEgeneric"],
                "geoRegion"hpa-version": ["USv1",
    "INTERNATIONAL"],    "hpa-feature-attributes": [
           {"networkTypehpa-attribute-key": ["ipnumaNodes"],
        , "hpa-attribute-value": "2", "operator": "=", "unit": ""},
           {"resourceInstanceTypehpa-attribute-key": ["vGMuxInfranumaCpu-0", "vG"]
       hpa-attribute-value":"2", "operator": "=", "unit": ""},
        },   {"hpa-attribute-key": "numaMem-0", "hpa-attribute-value":    "type": "placementOptimization",
            "objective": "minimize"
        }
    }
    Column
    width45%
    Expand
    titleComments and Notes: Optimization Policy

    The fields in this example policy are typically generated from a TOSCA service model specified by VNF vendors or service designers. This policy cannot be changed during the life-cycle of a service.

    ...

    TBD

    Modes for Fetching Policies

    OOF can fetch optimzation policies using the getConfig API of the policy system. The policies can be searched and filtered in two different modes; by-name and by-scope from the policy system.

    By-name: OOF can send an explicite policy name or a regular expression matching a set of policy names as a part of the getConfig API payload. In return, OOF expects to receive a specific policy or a set of policies with name matching to the regular expression.

    By-scope: A scope is the domain to which a policy is applicable. Scope information can be captured as a set of attribute-value pairs, which can be sent as a part of the getConfig API payload. In response, the policy system is expected to return a set of policies with the matching attribute-value pairs. A policy can only be included in the response if all the matching attribute-value pairs exist.

    ...

    "2048", "operator": "=", "unit": "MB"},
           {"hpa-attribute-key": "numaCpu-1", "hpa-attribute-value":"4", "operator": "=", "unit": ""},
           {"hpa-attribute-key": "numaMem-1", "hpa-attribute-value": "4096", "operator": "=", "unit": "MB"}
        ]
    }
    Column
    width45%
    Expand
    titleComments and Notes: HPA NUMA Policy

    The fields in this example policy are typically generated from a TOSCA service model specified by VNF vendors or service designers. This policy cannot be changed during the life-cycle of a service.

    Section
    bordertrue
    Column
    width60%
    Code Block
    languagejs
    themeEclipse
    titleHPA CPU Topology Policy Example
    linenumberstrue
    collapsetrue
    {
       "hpa-feature" : "cpuTopology",
       "mandatory" : "False",
       "score" : "5",
       "architecture": "generic",
       "hpa-version": "v1",
       "hpa-feature-attributes": [
          {"hpa-attribute-key":"numCpuSockets", "hpa-attribute-value": "2","operator": ">=", "unit": ""},
          {"hpa-attribute-key":"numCpuSockets", "hpa-attribute-value": "4","operator": "<=", "unit": ""},
          {"hpa-attribute-key":"numCpuCores", "hpa-attribute-value": "2", "operator":">=", "unit": ""},
          {"hpa-attribute-key":"numCpuCores", "hpa-attribute-value": "4", "operator":"<=", "unit": ""},
          {"hpa-attribute-key":"numCpuThreads", "hpa-attribute-value": "4", "operator":">=", "unit": ""},
          {"hpa-attribute-key":"numCpuThreads", "hpa-attribute-value": "8", "operator":"<=", "unit": ""}
       ]
    }
    Column
    width45%
    Expand
    titleComments and Notes: HPA CPU Topology Policy Example

    The fields in this example policy are typically generated from a TOSCA service model specified by VNF vendors or service designers. This policy cannot be changed during the life-cycle of a service.

    Section
    bordertrue
    Column
    width60%
    Code Block
    languagejs
    themeEclipse
    titleAffinity Policy Example
    linenumberstrue
    collapsetrue
    {
        "service": "affinityPolicy",
        "policyName": "oofBeijing.affinityPolicy_vcpe",
        "description": "Affinity policy for vCPE",
        "templateVersion": "1702.03",
        "version": "oofBeijing",
        "priority": "5",
        "riskType": "test",
        "riskLevel": "2",
        "guard": "False",
        "content": {
            "identity": "affinity_vCPE",
            "policyScope": ["vCPE", "US", "INTERNATIONAL", "ip", "vGMuxInfra"],
            "affinityProperties": {
                "qualifier": "different",
                "category": "complex"
            },
            "policyType": "affinityPolicy",
            "resources": ["vGMuxInfra", "vG"],
            "applicableResources": "all"
        }
    }
    Column
    width45%
    Expand
    titleComments and Notes: Affinity Policy

    The fields in this example policy are typically generated from a TOSCA service model specified by VNF vendors or service designers. This policy cannot be changed during the life-cycle of a service.

    Section
    bordertrue
    Column
    width60%
    Code Block
    languagejs
    themeEclipse
    titleCapacity Policy Example
    linenumberstrue
    collapsetrue
    {
        "service": "capacityPolicy",
        "policyName": "oofBeijing.capacityPolicy_vGMuxInfra",
        "description": "Capacity policy for vGMuxInfra",
        "templateVersion": "1702.03",
        "version": "oofBeijing",
        "priority": "5",
        "riskType": "test",
        "riskLevel": "2",
        "guard": "False",
        "content": {
            "identity": "capacity_vGMuxInfra",
            "policyScope": ["vCPE", "US", "INTERNATIONAL", "ip", "vGMuxInfra"],
    		"controller": "multicloud",
            "capacityProperties": {
                "cpu": {"value": 2, "operator": ">"},
                "memory": {"value": 4, "operator": ">", "unit": "GB"}
    			"storage": {"value": 80, "operator": ">", "unit": "GB"}
            },
            "policyType": "vim_fit",
            "resources": ["vGMuxInfra"],
            "applicableResources": "any"
        }
    }
    Column
    width45%
    Expand
    titleComments and Notes: Capacity Policy

    The fields in this example policy are typically generated from a TOSCA service model specified by VNF vendors or service designers. This policy cannot be changed during the life-cycle of a service.

    Section
    bordertrue
    Column
    width60%
    Code Block
    languagejs
    themeEclipse
    titleMin Guarantee Policy Example
    linenumberstrue
    collapsetrue
    {
        "service": "minGuaranteePolicy",
        "policyName": "oofBeijing.minGuaranee_vGMuxInfra",
        "description": "Min guarantee policy for vGMuxInfra",
        "templateVersion": "1702.03",
        "version": "oofBeijing",
        "priority": "5",
        "riskType": "test",
        "riskLevel": "2",
        "guard": "False",
        "content": {
            "identity": "minGuarantee_vGMuxInfra",
            "policyScope": ["vCPE", "US", "INTERNATIONAL", "ip", "vGMuxInfra"],
            "minGuaranteeProperty": {
                "cpu": "true",
                "memory": "false",
            },
            "type": "minGuaranteePolicy",
            "resources": ["vGMuxInfra"],
    		"applicableResources": "any"
        }
    }
    Column
    width45%
    Expand
    titleComments and Notes: Min Guarantee Policy

    The fields in this example policy are typically generated from a TOSCA service model specified by VNF vendors or service designers. This policy cannot be changed during the life-cycle of a service. A min-guarantee policy can be specified using the HPA policy model.

    Section
    bordertrue
    Column
    width60%
    Code Block
    languagejs
    themeEclipse
    titleOptimization Policy Example
    linenumberstrue
    collapsetrue
    {
        "service": "PlacementOptimizationPolicy",
        "policyName": "oofBeijing.PlacementOptimizationPolicy_vGMuxInfra",
        "description": "Placement Optimization Policy for vGMuxInfra",
        "templateVersion": "1702.03",
        "version": "oofBeijing",
        "priority": "5",
        "riskType": "test",
        "riskLevel": "3",
        "guard": "False",
        "content": {
            "objectiveParameter": {
                "parameterAttributes": [
                    {
                        "resources": ["vGMuxInfra"],
                        "customerLocationInfo": "customer_loc",
                        "parameter": "distance",
                        "weight": "1",
                        "operator": "product"=
                    },
                    {
                        "resources": ["vG"],
                        "customerLocationInfo": "customer_loc",
                        "parameter": "distance",
                        "weight": "1",
                        "operator": "product"
                    }
                ],
                "operator": "sum"
            },
            "identity": "optimization",
            "policyScope": ["vCPE", "US", "INTERNATIONAL", "ip", "vGMuxInfra"],
            "policyType": "placementOptimization",
            "objective": "minimize"
        }
    }
    Column
    width45%
    Expand
    titleComments and Notes: Optimization Policy

    The fields in this example policy are typically generated from a TOSCA service model specified by VNF vendors or service designers. This policy cannot be changed during the life-cycle of a service.



    Section
    bordertrue
    Column
    width60%
    Code Block
    languagejs
    themeEclipse
    titleHPA PCIe Policy Example
    linenumberstrue
    collapsetrue
    {
        "hpa-feature" : "pcie",
        "mandatory" : "False",
        "score" : "5",
        "architecture": "generic",
        "hpa-version": "v1",
        "hpa-feature-attributes": [
          {"hpa-attribute-key": "pciCount", "hpa-attribute-value": "2", "operator": "=", "unit": ""},
          {"hpa-attribute-key": "pciVendorId", "hpa-attribute-value":"8086", "operator": "=", "unit": ""},
    	  {"hpa-attribute-key": "pciDeviceId", "hpa-attribute-value": "2", "operator": "=", "unit": ""} 
          {"hpa-attribute-key": "functionType", "hpa-attribute-value": "<PCIETYPEVALUE>","operator": "=", "unit": ""} 
         ]
    }
    Column
    width45%
    Expand
    titleComments and Notes: HPA PCIe Policy Example

    PCIETYPEVALUE: SRIOV, PCI-PASSTHROUGH

    Section
    bordertrue
    Column
    width60%
    Code Block
    languagejs
    themeEclipse
    titleHPA Local Storage Policy Example
    linenumberstrue
    collapsetrue
    {
        "hpa-feature" : "localStorage",
        "mandatory" : "False",
        "score" : "5",
        "architecture": "generic",
        "hpa-version": "v1",
        "hpa-feature-attributes": [
           {"hpa-attribute-key": "diskSize", "hpa-attribute-value": "2", "operator": "=", "unit": "GB"},   
           {"hpa-attribute-key": "ephemeralDiskSize", "hpa-attribute-value": "2", "operator": "=", "unit": "GB"},
    	   {"hpa-attribute-key": "swapMemSize", "hpa-attribute-value":"16", "operator": "=", "unit": "MB"},
         ]
    }
    Column
    width45%
    Expand
    titleComments and Notes: HPA Generic Attributes Policy Example

    The fields in this example policy are typically generated from a TOSCA service model specified by VNF vendors or service designers. This policy cannot be changed during the life-cycle of a service.

    Section
    bordertrue
    Column
    width60%
    Code Block
    languagejs
    themeEclipse
    titleHPA CPU Instruction Set Extensions Policy Example
    linenumberstrue
    collapsetrue
    {
        "hpa-feature" : "cpuInstructionSetExtensions",
        "mandatory" : "False",
        "score" : "5",
        "architecture": "INTEL-64",
        "hpa-version": "v1",
        "hpa-feature-attributes": [
          {"hpa-attribute-key":"instructionSetExtensions", "hpa-attribute-value":["<CPUINST>", "<CPUINST>"] "operator": "ALL", "unit":""}
         ]
    }
    Column
    width45%
    Expand
    titleComments and Notes: HPA CPU Instruction Set Extensions Policy Example
    instructionSetExtensions attribute has a list of all instruction set extensions required. 
    CPUINST = aes, avx, sha_ni, mpx, adcx, mpx, pclmulqdq, rdrand,sse, etc
    Section
    bordertrue
    Column
    width60%
    Code Block
    languagejs
    themeEclipse
    titleHPA Huge Pages Policy Example
    linenumberstrue
    collapsetrue
    {
        "hpa-feature" : "hugePages",
        "mandatory" : "False",
        "score" : "5",
        "architecture": "generic",
        "hpa-version": "v1",
        "hpa-feature-attributes": [
          {"hpa-attribute-key": "memoryPageSize", "hpa-attribute-value": "<MEMORYPAGESIZE>", "operator": "=", "unit": ""}
        ]
    }
    Column
    width40%
    Expand
    titleComments and Notes: HPA Huge Pages Policy Example

    MEMORYPAGESIZE = 4KB (unit=KB), 2MB (unit=MB), 1GB(unit GB), ANY, Other explicit Page size

    Section
    bordertrue
    Column
    width60%
    Code Block
    languagejs
    themeEclipse
    titleVNF Policy Example
    linenumberstrue
    collapsetrue
    {
        "service": "vnfPolicy",
        "policyName": "oofBeijing.vnfPolicy_vGMuxInfra",
        "description": "vnfPolicy",
        "templateVersion": "1702.03",
        "version": "oofBeijing",
        "priority": "6",
        "riskType": "test",
        "riskLevel": "3",
        "guard": "False",
        "content": {
            "identity": "vnf_vGMuxInfra",
            "policyScope": ["vCPE", "INTERNATIONAL", "ip", "vGMuxInfra"],
            "policyType": "vnf_policy",
            "resources": ["vGMuxInfra"],
            "applicableResources": "any",
            "vnfProperties": [
                {
                    "inventoryProvider": "aai",
                    "serviceType": "",
                    "inventoryType": "cloudRegionId",
                    "customerId": ""
                },
                {
                    "inventoryProvider": "multicloud",
                    "serviceType": "HNGATEWAY",
                    "inventoryType": "serviceInstanceId",
                    "customerId": "21014aa2-526b-11e6-beb8-9e71128cae77"
                }
            ]
        }
    }
    Column
    width40%
    Expand
    titleComments and Notes: HPA Huge Pages Policy Example

    VNF policy captures the location of inventories and customer information.

    Section
    bordertrue
    Column
    width60%
    Code Block
    languagejs
    themeEclipse
    titleSubscriber Role Policy Example
    linenumberstrue
    collapsetrue
    {
     "service": "SubscriberPolicy",
     "policyName": "oofBeijing.SubscriberPolicy_v1",
     "description": "Subscriber Policy",
     "templateVersion": "0.0.1",
     "version": "oofBeijing",
     "priority": "1",
     "riskType": "test",
     "riskLevel": "3",
     "guard": "False",
     "content": {
            "identity": "subscriber",
            "policyScope": ["vCPE", "subscriber_x", "subscriber_y"],
            "properties": {
                    "subscriberName": ["subscriber_x", "subscriber_y"],
                    "subscriberRole": ["Test"],
                    "provStatus": ["CAPPED"]
            },
            "policyType": "SubscriberPolicy"
     }
    }
    Column
    width40%
    Expand
    titleComments and Notes: HPA Huge Pages Policy Example

    Subscriber role policy to capture the role of a subscriber and related provisioning states.

    Anchor
    OOF-CMSO Policies
    OOF-CMSO Policies
    OOF-CMSO Policies

    TBD

    Modes for Fetching Policies

    OOF can fetch optimzation policies using the getConfig API of the policy system. The policies can be searched and filtered in two different modes; by-name and by-scope from the policy system.

    By-name: OOF can send an explicite policy name or a regular expression matching a set of policy names as a part of the getConfig API payload. In return, OOF expects to receive a specific policy or a set of policies with name matching to the regular expression.

    By-scope: A scope is the domain to which a policy is applicable. Scope information can be captured as a set of attribute-value pairs, which can be sent as a part of the getConfig API payload. In response, the policy system is expected to return a set of policies with the matching attribute-value pairs. A policy can only be included in the response if all the matching attribute-value pairs exist.

    OOF can requerst prioritization by enabling a prioritization flag in the getConfig API call to the policy system, and expects to receive a single policy with the highest priority policy among the set of policies meeting the search criteria.

    TOSCA Policy Models

    The following TOSCA policy models need to be uploaded as a dictionary during the deployment-time of an optimization application. Currently, the model uploading porcess is manual since the policy system does not offer an interface to upload models programatically. Once the models are uploaded, policy templates are created in the policy portal/GUI using which optimization policies can be created. Alternatively, the policy system offers CRUD REST APIs using which the policies can be managed by the application.

    HAS Policies for Testing

    View file
    nameAffinity_vCPE_1.json
    height250
    View file
    nameCapacity_vG_1.json
    height250
    View file
    nameCapacity_vGMuxInfra.json
    height250
    View file
    nameDistance_vG_1.json
    height250
    View file
    nameDistance_vGMuxInfra_1.json
    height250
    View file
    namehpa_policy_vG_1.json
    height250
    View file
    namehpa_policy_vGMuxInfra_1.json
    height250
    View file
    namePlacement_Optimization_1.json
    height250
    View file
    nameQueryPolicy_vCPE.json
    height250
    View file
    namesubscriber_policy.json
    height250
    View file
    namevnfPolicy_vG.json
    height250
    View file
    namevnfPolicy_vGMuxInfra.json
    height250