OOF-AAI Interaction in R2



AAI Schema Changes  Refer → Persistence of HPA related information in AAI

HPACapabilities

Given a list of HPACapabilities as requirements, return the candidate list of (cloud region + flavor_reference) such that there exist at least one flavor with all HPACapabilities satisfied.

Naive Approach relying of resources micro service

  1. GET /cloud-infrastructure/cloud-regions (depth=0)

  2. From the list of cloud regions return list of cloud region matching all the mandatory HPA capabilities.  (Is there a way to efficiently do this in AAI to avoid step1)

  3. For Each cloud region from cloud_regions (from prev step)

    1. GET /cloud-infrastructure/cloud-regions/cloud-region/{cloud-owner}/{cloud-region-id}/flavors

    2. For Each flavor 

      1. Get RelationshipList and find the list of capabilities.

      2. Match the requirement with the list of capabilities

      3. Add the (cloud region + flavor_reference) to candidate list of cloud region

Desired Approach

  1. Get all flavors that satisfies all HPACapability requirements (HPA1 AND HPA2 AND HPA3) 

  2. Add all (cloud region + flavor_reference) to candidate list of cloud region

If using Naive approach how to efficiently do step 2 so that we don't have to parse all cloud regions.



Unknowns:

Min Guarantee Capabilities

Get a list of canditate cloud regions and flavor references that satisfies the minimum guarantee requirements. For eg: cpu = 4, memory = 8GB

Question : Similar to HPACapabilities. Can we rely on flavors to get this information?

Location 

Existing Service location.

Given the service details identify the cloud-region and the location details from complex.

Since this is a service we need to identify where it can get cloud-region and Complex

service-instance → cloud-region → complex  → (lat,long)

CloudAffinity

Given a cloud-region identify the location details from complex.

  1. GET /network/generic-vnfs?prov-status=PROV&equipment-role={}

  2. For Each vnf in generic-vnfs

    1. Get RelationshipList and find the list of vservers.

    2. For Each vserver in vservers list

      1. Get RelationshipList and find the pserver.

      2. Using the URL from relationship data get the pserver details /cloud-infrastructure/pservers/pserver 

        1. Get RelationshipList and find the cloud-region

        2. Using the URL from relationship data get the cloud-region details

          1. Get complex information and location information

generic-vnf → vserver → pserver → complex  → (lat,long)

generic-vnf →  complex  → (lat,long)

Unknowns :

  • Does VIM onboarding ensures the complex information is populated and the relationship between Cloud-region and complex established? 

  • Confirm with ESR if this association between complex and cloud-region will be taken care - Looks like yes. Ask ESR.