Versions Compared

Key

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

...

Gliffy Diagram
size1200
namevCPEPoliciesAndInformationSources
pagePin18


Homing Workflow

...


SO - HAS API (R) - before retrieving homing policies

Code Block
languagetext
titleSO - HAS API (R)
collapsetrue
requestInfo:

...


  callbackUrl: https://so:5000/callback
  numSolutions: 1
  optimizer:
  - placement
  requestId: yyy-yyy-yyyy
  sourceId: so
  timeout: 600
  transactionId: xxx-xxx-xxxx
  requestType: new
placementInfo:
  orderInfo:
    requestParameters:
      customerLatitude: 32.897480
      customerLongitude: -97.040443
      customerName: some_company
  demandInfo:
    placementDemands:
    - resourceName: vGMuxInfra
      resourceId: some_resource_id
      tenantId: some_tenant_id
      resourceModelInfo:
        modelId: vGMux_model_id
        modelName: ''
        modelType: allotted
        modelVersion: '2.0'
      existingPlacement:
        serviceInstanceId: 87257b49-9602-4ca1-9817-094e52bc873b
      excludedCandidates:
      - candidateType: service
        candidates:
        - serviceInstanceId: 1ac71fb8-ad43-4e16-9459-c3f372b8236d

...


      requiredCandidates:
      - candidateType: service 

...


        candidates:
        - serviceInstanceId: 7e6c3e57-62cd-44f6-aa88-d0896998f7ec

...


    - resourceName: vG
      tenantId: some_tenant_id
      resourceId: 71d563e8-e714-4393-8f99-cc480144a05e
      resourceModelInfo:
        modelId: vG_model_id
        modelName: ''
        modelType: dedicated
        modelVersion: '2.0'
      existingPlacement:
        serviceInstanceId: 21d5f3e8-e714-4383-8f99-cc480144505a
      excludedCandidates:
      - candidateType: service
        candidates:
        - serviceInstanceId: 1ac71fb8-ad43-4e16-9459-c3f372b8236d

...


      requiredCandidates:
      - candidateType: cloud
        candidates:
        - cloud-region-id: TXAUS219

...



  otherInfo:
    serviceInstanceId: d61b2543-5914-4b8f-8e81-81e38575b8ec
  serviceModelInfo:
    serviceName: Residential vCPE
    service_id: vcpe_service_id
    serviceType: service
    serviceVersion: '1.0'


HAS Homing Specification (R') - after retrieving and translating homing policies

Code Block
languagejs
titlevCPE Homing Template (JSON)
collapsetrue
{
  "homing_template_version": "2017-10-10",
  "parameters": {
    "service_name": "Residential vCPE",
    "service_id": "vcpe_service_id",
    "customer_lat": 32.89748,
    "customer_long": -97.040443,
    "REQUIRED_MEM": 4,
    "REQUIRED_DISK": 100,
    "pnf_id": "some_pnf_id"
  },
  "locations": {
    "customer_loc": {
      "latitude": {
        "get_param": "customer_lat"
      },
      "longitude": {
        "get_param": "customer_long"
      }
    },
  },
  "brg_locdemands": {
      "pnf_host_namevGMuxInfra": [
      {
        "getinventory_paramprovider": "pnf_idaai",
      }
    }
  },
  "demands": {
    "vGMuxInfra": [
      {
        "inventory_provider": "aai""inventory_type": "service",
        "inventory_type": "service",
        "attributes": {
          "equipment_type": "vG_Mux",
          "customer_id": "some_company"
        },
        "excluded_candidates": [
          {
            "candidate_id": "1ac71fb8-ad43-4e16-9459-c3f372b8236d"
          }
        ],
        "existing_placement": [
          {
            "candidate_id": "21d5f3e8-e714-4383-8f99-cc480144505a"
          }
        ]
      }
    ],
    "vG": [
      {
        "inventory_provider": "aai",
        "inventory_type": "cloud"
      }
    ]
  },
  "constraints": [
    {
      "constraint_vgmux_customer": {
        "type": "distance_to_location",
        "demands": [
          "vGMuxInfra"
        ],
        "properties": {
          "distance": "< 100 km",
          "location": "customer_loc"
        }
      },
    },
    {
      ""colocation": {
        "type": "zone",
        "demands": [
          "vGMuxInfra",
          "vG"
        ],
        "properties": {
          "qualifier": "same",
          "category": "region"
        }
      }
    },
    {
      "hpa_constraint": {
        "type": "hpa",
        "demands": [
          "vG"
        ],
        "properties": {
          "evaluate": [
            {
              "labelflavorLabel": "flavor_label_1",
              "featuresflavorProperties": [
                {
                  "hpa-feature": "basicCapabilities",
                  "hpa-version": "v1",
                  "architecture": "generic",
                  "hpa-feature-attributes": [
                    {
                      "hpa-attribute-key": "numVirtualCpu",
                      "hpa-attribute-value": "4",
                      "operator": "="
                    },
                    {
                      "hpa-attribute-key": "virtualMemSize",
                      "hpa-attribute-value": "4",
                      "operator": "=",
                      "unit": "GB"
                    }
                  ]
                },
                {
                  "hpa-feature": "numa",
                  "hpa-version": "v1",
                  "architecture": "generic",
                  "hpa-feature-attributes": [
                    {
                      "hpa-attribute-key": "numaNodes",
                      "hpa-attribute-value": "2",
                      "operator": "="
                    },
                    {
                      "hpa-attribute-key": "numaCpu-0",
                      "hpa-attribute-value": "2",
                      "operator": "="
                    },
                    {
                      "hpa-attribute-key": "numaCpu-1",
                      "hpa-attribute-value": "4",
                      "operator": "="
                    },
                    {
                      "hpa-attribute-key": "numaMem-0",
                      "hpa-attribute-value": "2",
                      "operator": "=",
                      "unit": "GB"
                    },
                    {
                      "hpa-attribute-key": "numaMem-1",
                      "hpa-attribute-value": "4",
                      "operator": "=",
                      "unit": "GB"
                    }
                  ]
                },
                {
                  "hpa-feature": "cpuPinning",
                  "hpa-version": "v1",
                  "architecture": "generic",
                  "hpa-feature-attributes": [
                    {
                      "hpa-attribute-key": "logicalCpuThreadPinningPolicy",
                      "hpa-attribute-value": "prefer",
                      "operator": "="
                    },
                    {
                      "hpa-attribute-key": "logicalCpuPinningPolicy",
                      "hpa-attribute-value": "dedicated",
                      ""operator": "="
                    }
                  ]
                }
              ]
            },
            {
              "labelflavorLabel": "flavor_label_2",
              "featuresflavorProperties": [
                {
                  "hpa-feature": "basicCapabilities",
                  "hpa-version": "v1",
                  "architecture": "generic",
                  "hpa-feature-attributes": [
                    {
                      "hpa-attribute-key": "numVirtualCpu",
                      "hpa-attribute-value": "8",
                      "operator": "="
                    },
                    {
                      "hpa-attribute-key": "virtualMemSize",
                      "hpa-attribute-value": "16",
                      "operator": "=",
                      "unit": "GB"
                    }
                  ]
                },
                {
                  "hpa-feature": "numa",
                  "hpa-version": "v1",
                  "architecture": "generic",
                  "hpa-feature-attributes": [
                    {
                      "hpa-attribute-key": "numaNodes",
                      "hpa-attribute-value": "2",
                      "operator": "="
                    },
                    {
                      "hpa-attribute-key": "numaCpu-0",
                      "hpa-attribute-value": "2",
                      "operator": "="
                    },
                    {
                      "hpa-attribute-key": "numaCpu-1",
                      "hpa-attribute-value": "4",
                      "operator": "="
                    },
                    {
                      "hpa-attribute-key": "numaMem-0",
                      "hpa-attribute-value": "2",
                      "operator": "=",
                      "unit": "GB"
                    },
                    {
                      "hpa-attribute-key": "numaMem-1",
                      "hpa-attribute-value": "4",
                      "operator": "=",
                      "unit": "GB"
                    }
                  ]
                },
                {
                  "hpa-feature": "memoryPageSize",
                  "hpa-version": "v1",
                  "architecture": "generic",
                  "hpa-feature-attributes": [
                    {
                      "hpa-attribute-key": "memoryPageSize",
                      "hpa-attribute-value": "2",
                      "operator": "=",
                      "unit": "GB"
                    }
                  ]
                }
              ]
            }
          ]
        }
      }
    },
    {
      "check_cloud_min_guaranteecapacity": {
        "type": "attributevim_fit",
        "demands": [
          "vG"
        ],
        "properties": {
          "evaluatecontroller": {"multicloud",
            "cpu_min_guarantee"request": true,{
            "mem_min_guarantee"vCPU": true10,
          }"Memory": {
        }
      }"quantity": {
    },
    {
      "checkget_cloud_capacityparam": null,"REQUIRED_MEM"
      "type": "vim_fit",
      },
            "demandsunit": ["GB"
        "vG"
  },
    ],
      "propertiesStorage": {
        "vim-controller": "multicloud",
        "requestquantity": {
          "vCPU    "get_param": 10,"REQUIRED_DISK"
          "mem": {  },
            "quantityunit": {"GB"
          }
     "get_param": "REQUIRED_MEM"   }
      }
    }
  },
  "optimization": {
    "minimize": {
      "unitsum": "GB"[
          },{
          "diskdistance_between": {[
            "quantity": {customer_loc",
              "get_param": "REQUIRED_DISK""vGMuxInfra"
            },]
        },
    "unit": "GB"
   {
       }
        }"distance_between": [
      }
    }
  ]"customer_loc",
  "optimization": {
    "minimize": {
      "sumvG": [
        {
  ]
        "distance_between": [}
      ]
      "customer_loc",}
  }
}



Code Block
languagetext
titlevCPE Homing Template (YAML)
collapsetrue
---
homing_template_version: '2017-10-10'
parameters:
  service_name: Residential vCPE
  service_id: vcpe_service_id
  customer_lat: 32.89748
  customer_long: -97.040443
  REQUIRED_MEM: 4
  REQUIRED_DISK: 100
locations:
  customer_loc:
    latitude:
      get_param: customer_lat
    longitude:
      get_param: customer_long
demands:
  vGMuxInfra:
  - inventory_provider: aai
    inventory_type: service
    attributes:
      equipment_type: vG_Mux
      customer_id: some_company
    excluded_candidates:
    - candidate_id: 1ac71fb8-ad43-4e16-9459-c3f372b8236d
    existing_placement:
    - candidate_id: 21d5f3e8-e714-4383-8f99-cc480144505a
  vG:
  - inventory_provider: aai
    inventory_type: cloud
constraints:
  constraint_vgmux_customer:
    type: distance_to_location
    demands:
    - vGMuxInfra
    properties:
      distance: "< 100 km"
      location: customer_loc
  colocation:
    type: zone
    demands:
    - vGMuxInfra
    - vG
    properties:
      qualifier: same
      category: region
  hpa_constraint:
    type: hpa
    demands:
    - vG
    properties:
      evaluate:
      - flavorLabel: flavor_label_1
        flavorProperties:
        - hpa-feature: basicCapabilities
          hpa-version: v1
          architecture: generic
          hpa-feature-attributes:
          - hpa-attribute-key: numVirtualCpu
            hpa-attribute-value: '4'
            operator: "="
          - hpa-attribute-key: virtualMemSize
            hpa-attribute-value: '4'
            operator: "="
            unit: GB
        - hpa-feature: numa
          hpa-version: v1
          architecture: generic
          hpa-feature-attributes:
          - hpa-attribute-key: numaNodes
            hpa-attribute-value: '2'
            operator: "="
          - hpa-attribute-key: numaCpu-0
            hpa-attribute-value: '2'
            operator: "="
          - hpa-attribute-key: numaCpu-1
            hpa-attribute-value: '4'
            operator: "vGMuxInfra="
           ]
- hpa-attribute-key: numaMem-0
            hpa-attribute-value: '2'
         },
   operator: "="
          {
  unit: GB
           "distance_between": [- hpa-attribute-key: numaMem-1
            "customer_loc",
hpa-attribute-value: '4'
            operator: "vG="
          ]
  unit: GB
     }
    - hpa-feature: ]cpuPinning
    }
  }
}


Code Block
languagetext
titlevCPE Homing Template (YAML)
collapsetrue
---
homing_template_version: '2017-10-10'
parameters:
  service_name: Residential vCPE
  service_id: vcpe_service_id
  customer_lat: 32.89748
  customer_long: -97.040443
  REQUIRED_MEM: 4
  REQUIRED_DISK: 100
  pnf_id: some_pnf_id
locations:
  customer_loc:
    latitude hpa-version: v1
          architecture: generic
          hpa-feature-attributes:
      get_param: customer_lat
   - longitude:hpa-attribute-key: logicalCpuThreadPinningPolicy
      get_param: customer_long
  brg_loc:      hpa-attribute-value: prefer
    pnf_host_name:
       get_param: pnf_id
demands: operator: "="
  vGMuxInfra:
   - inventory_provider: aai
    inventory_type- hpa-attribute-key: servicelogicalCpuPinningPolicy
      attributes:
      equipment_typehpa-attribute-value: vG_Muxdedicated
       customer_id: some_company
    excluded_candidates:operator: "="
    - candidate_id: 1ac71fb8-ad43-4e16-9459-c3f372b8236d
    existing_placement:flavorLabel: flavor_label_2
    - candidate_id: 21d5f3e8-e714-4383-8f99-cc480144505a
    vGflavorProperties:
        - inventory_providerhpa-feature: aaibasicCapabilities
    inventory_type: cloud
constraints:
- constraint_vgmux_customer:
    typehpa-version: distance_to_locationv1
     demands:
     -architecture: vGMuxInfrageneric
    properties:
      distancehpa-feature-attributes:
 "< 100 km"
      location: customer_loc
- colocation:hpa-attribute-key: numVirtualCpu
    type: zone
    demands:
    hpa-attribute-value: vGMuxInfra'8'
    - vG
    properties:
   operator: "="
  qualifier: same
      category: region
- hpa_constraint:-attribute-key: virtualMemSize
    type: hpa
    demands:
    hpa-attribute-value: vG'16'
    properties:
      evaluate:
  operator: "="
   - label: flavor_label_1
       unit: features:GB
        - hpa-feature: basicCapabilitiesnuma
          hpa-version: v1
          architecture: generic
          hpa-feature-attributes:
          - hpa-attribute-key: numVirtualCpunumaNodes
            hpa-attribute-value: '42'
            operator: "="
          - hpa-attribute-key: virtualMemSizenumaCpu-0
            hpa-attribute-value: '4'
            operator: "=": '2'
            unitoperator: GB"="
          - hpa-attribute-featurekey: numanumaCpu-1
            hpa-versionattribute-value: v1'4'
          architecture  operator: generic"="
          - hpa-featureattribute-attributeskey: numaMem-0
          -  hpa-attribute-keyvalue: numaNodes'2'
            hpa-attribute-valueoperator: '2'"="
            operatorunit: "="GB
          - hpa-attribute-key: numaCpunumaMem-01
            hpa-attribute-value: '2'4'
            operator: "="
            operatorunit: "="GB
          - hpa-attribute-keyfeature: numaCpu-1memoryPageSize
            hpa-attribute-valueversion: '4'v1
          architecture:  operator: "="generic
          hpa-feature-attributes:
          - hpa-attribute-key: numaMem-0memoryPageSize
            hpa-attribute-value: '2'
            operator: "="
            unit: GB
  check_cloud_capacity: 
    type: vim_fit
  - hpa-attribute-key: numaMem-1  demands:
    - vG
    properties:
      controller:  hpa-attribute-value: '4'
multicloud
      request:
        operatorvCPU: "="
10
        Memory:
         unit quantity:
   GB
        - hpa-feature get_param: cpuPinningREQUIRED_MEM
          hpa-versionunit: v1GB
          architectureStorage: generic
          hpa-feature-attributesquantity:
          - hpa-attribute-key: logicalCpuThreadPinningPolicy  get_param: REQUIRED_DISK
          unit: GB
optimization:
  hpa-attribute-valueminimize:
 prefer   sum:
    - distance_between:
       operator: "="- customer_loc
      - vGMuxInfra
    - hpa-attribute-key: logicalCpuPinningPolicydistance_between:
      - customer_loc
      hpa-attribute-value: dedicated- vG




HAS Homing Response

State - Done

Code Block
languagejs
titlevCPE homing response (JSON)
collapsetrue
{
  "plans": [
    {
        operator"status": "=done",
      - label"id": flavor_label_2"plan_id",
        features:
   "name": "Plan Name 1",
     - hpa-feature "links": basicCapabilities[
        [
  hpa-version: v1
       {
   architecture: generic
          hpa-feature-attributes:"href": "http://conductor:8091/v1/plans/plan_id",
          - hpa-attribute-key: numVirtualCpu
  "rel": "self"
          }
   hpa-attribute-value: '8'
    ]
      ],
  operator: "="
   "recommendations": [
      - hpa-attribute-key: virtualMemSize {
            hpa-attribute-value"vG": '16'{
            operator"inventory_provider": "=aai",
            unit"candidate": GB{
        - hpa-feature: numa
    "candidate_id": "DLLSTX1A",
     hpa-version: v1
          architecture"cloud_owner": generic"CloudOwner1",
          hpa-feature-attributes:
          - hpa-attribute-key: numaNodes"inventory_type": "cloud",
            hpa-attribute-value: '2'  "location_id": "DLLSTX1A",
            operator  "location_type": "=openstack-cloud"
          - hpa-attribute-key: numaCpu-0 },
            hpa-attribute-value"attributes": '2'{
             operator: "=flavors": {
               - hpa-attribute-key: numaCpu-1
 "flavor_label_1": "vim_flavor_X",
                hpa-attribute-value: '4'"flavor_label_2": "vim_flavor_Y"
            operator: "="  },
          - hpa-attribute-key: numaMem-0    "cloud_owner": "CloudOwner1",
            hpa-attribute-value: '2'
  "physical-location-id": "DLLSTX1A",
              "cloud_version": "3.0",
			  operator"vim-id": "=CloudOwner1_DLLSTX1A"
            unit: GB}
          - hpa-attribute-key: numaMem-1}
        },
    hpa-attribute-value: '4'
   {
         operator: "=vGMuxInfra": {
            unit"attributes": GB{
        - hpa-feature: memoryPageSize
          hpa-version: v1"host_id": "vgmux_host_name",
          architecture: generic
          hpa-feature-attributes:
"cloud_owner": "CloudOwner1",
           -   hpa"physical-attributelocation-keyid": memoryPageSize"DLLSTX1A",
            hpa-attribute-value: '2'
  "service_instance_id": "21d5f3e8-e714-4383-8f99-cc480144505a",
              operator"cloud_version": "=3.0",
			  "vim-id": "CloudOwner1_DLLSTX1A"
         unit: GB
- cloud_min_guarantee:
    type: attribute
  },
   demands:
    - vG
    properties:"inventory_provider": "aai",
      evaluate:
        cpu_min_guarantee: true"service_resource_id": "12345",
        mem_min_guarantee: true
- check_cloud_capacity:     "candidate": {
  type: vim_fit
  demands:
  - vG
  properties:
    vim-controller"is_rehome": multicloud"false",
    request:
          vCPU"location_id": 10"DLLSTX1A",
      mem:
        quantity:
"inventory_type": "service",
              get"candidate_param: REQUIRED_MEMid": "21d5f3e8-e714-4383-8f99-cc480144505a",
        unit: GB
      disk:"host_id": "vgmux_host_name",
        quantity:
      "cloud_owner": "CloudOwner1",
    get_param: REQUIRED_DISK
          unit"location_type": GB
optimization:
"openstack-cloud"
   minimize:
    sum:
    - distance_between:}
      - customer_loc
   }
   - vGMuxInfra
    - distance_between:}
      - customer_loc]
    }
  - vG

...

]
}


State - Error 

Code Block
languagejs
titlevCPE homing response (JSON)HAS Error Response
collapsetrue
{
  "recommendations": [
    {
      "vG": {
        "inventory_provider": "aai",
        "candidate"plans": {[
    {
      "candidate_idstatus": "DLLSTX1Aerror",
          "cloud_ownermessage": "rackspaceSome error message",
          "inventory_typename": "cloudPlan Name 1",
      "links": [
   "is_rehome": false,
     [
          {
  "location_id": "DLLSTX1A",
         "href": "location_type": "openstack-cloud",
http://conductor:8091/v1/plans/plan_id",
            "vim-idrel": "rackspace_DLLSTX1Aself"
          },
        ]
 "attributes": {
    ],
      "flavorsid": {"plan_id"
              "flavor_label_1}
  ]
}


State - Template 

Code Block
languagejs
titleHAS Plan in Template State
collapsetrue
{
  "status": "vim_flavor_Xtemplate",
              "flavor_label_2": "vim_flavor_Y""name": "Plan Name 1",
  "links": [
    [
      },{
          "physical-location-id"href": "DLLSTX1223"http://conductor:8091/v1/plans/plan_id",
        }"rel": "self"
      }
    },]
    {],
  "id": "plan_id"
}


State - Solving

Code Block
languagejs
titleHAS Plan in Solving state
collapsetrue
{
  "plans": [    "vGMuxInfra": {
        "inventory_provider": "aai",
        "candidate": {
          "candidate_id"status": "21d5f3e8-e714-4383-8f99-cc480144505asolving",
          "cloud_owner"name": "rackspacePlan Name 1",
          "host_idlinks": "vgmux_host_name",[
          "inventory_type": "service",
[
           "is_rehome": false,
{
            "location_idhref": "DLLSTX1Ahttp://conductor:8091/v1/plans/plan_id",
            "location_typerel": "openstack-cloudself",
		  "vim-id": "rackspace_DLLSTX1A"
        },
        ]
 "attributes": {
    ],
      "physical-location-id": "DLLSTX1223plan_id"
        }
      }
    }
  ]
}