Skip to end of metadata
Go to start of metadata

A&AI Schema


ComputeNode, HPACapacity schema


      


Modified AAI Schema
		<java-type name="ComputeNodes">
			<xml-properties>
				<xml-property name="description" value="List of ComputeNodes in a CloudRegion"/>
			</xml-properties>
			<xml-root-element name="compute-nodes"/>
			<java-attributes>
				<xml-element container-type="java.util.ArrayList" java-attribute="computeNode" name="compute-node" type="inventory.aai.onap.org.v14.ComputeNode"/>
			</java-attributes>
		</java-type>

		<java-type name="ComputeNode">
			<xml-root-element name="compute-node"/>
			<java-attributes>
				<xml-element java-attribute="nodeName" name="node-name" required="true" type="java.lang.String" xml-key="true">
					<xml-properties>
						<xml-property name="description" value="UUID to uniquely identify a HPA capability"/>
					</xml-properties>
				</xml-element>
				<xml-element java-attribute="resourceVersion" name="resource-version" type="java.lang.String">
					<xml-properties>
						<xml-property name="description" value="Used for optimistic concurrency.  Must be empty on create, valid on update and delete."/>
					</xml-properties>
				</xml-element>
				<xml-element java-attribute="relationshipList" name="relationship-list" type="inventory.aai.onap.org.v14.RelationshipList"/>
				<xml-element container-type="java.util.ArrayList" java-attribute="hpaCapacity" name="hpa-capacity" type="inventory.aai.onap.org.v14.HpaCapacity"/>
			</java-attributes>
			<xml-properties>
				<xml-property name="description" value="Represents a Compute Node with HPA capacity information"/>
				<xml-property name="indexedProps" value="node-name"/>
				<xml-property name="dependentOn" value="cloud-region"/>
				<xml-property name="container" value="compute-nodes"/>
			</xml-properties>
		</java-type>

		<java-type name="HpaCapacity">
			<xml-root-element name="hpa-capacity"/>
			<java-attributes>
				<xml-element java-attribute="hpaCapacityKey" name="hpa-capacity-key" required="true" type="java.lang.String" xml-key="true">
					<xml-properties>
						<xml-property name="description" value="Composite key formed with hpaFeature and append list of hpaFeatureAttributes needed for capacity check"/>
					</xml-properties>
				</xml-element>
				<xml-element java-attribute="hpaCapacityValue" name="hpa-capacity-value" type="java.lang.String">
					<xml-properties>
						<xml-property name="description" value="JSON string specifying the capacity (total,free), unit and metadata of the specific HPA attribute"/>
					</xml-properties>
				</xml-element>
				<xml-element java-attribute="resourceVersion" name="resource-version" type="java.lang.String">
					<xml-properties>
						<xml-property name="description" value="Used for optimistic concurrency.  Must be empty on create, valid on update and delete."/>
					</xml-properties>
				</xml-element>
				<xml-element java-attribute="relationshipList" name="relationship-list" type="inventory.aai.onap.org.v14.RelationshipList"/>
			</java-attributes>
			<xml-properties>
				<xml-property name="description" value="HPA Capability Feature attributes"/>
				<xml-property name="indexedProps" value="hpa-attribute-key"/>
				<xml-property name="dependentOn" value="hpa-capability"/>
			</xml-properties>
		</java-type>
Edge Relations
{
	"from": "compute-node",
	"to": "cloud-region",
	"label": "org.onap.relationships.inventory.BelongsTo",
	"direction": "OUT",
	"multiplicity": "MANY2ONE",
	"contains-other-v": "!${direction}",
	"delete-other-v": "NONE",
	"SVC-INFRA": "NONE",
	"prevent-delete": "!${direction}",
	"default": "true",
	"description":""
},
{
	"from": "compute-node",
	"to": "flavor",
	"label": "org.onap.relationships.inventory.AssociatedWith",
	"direction": "OUT",
	"multiplicity": "MANY2MANY",
	"contains-other-v": "!${direction}",
	"delete-other-v": "NONE",
	"SVC-INFRA": "NONE",
	"prevent-delete": "!${direction}",
	"default": "true",
	"description":""
}

Changes Required in OOF HPA constraint

Match Flavor Function (per vnfc)

For each flavor in cloud-region-flavor-list

    For each hpaCapability in HPACapabilities requirement     

              Match hpaCapability in flavor

                If matching hpaCapability found,

                   Check-Capacity(hpaCapacityKey, flavor, threshold).


Check-Capacity Function(input: hpaCapacityKey, flavor, threshold)

Get the compute Nodes associated with the input flavor.

     getHPACapacityValue(hpaCapacityKey)

     if( (free/total) < threshold): //Not enough capacity

         return False and add to discard set

     else:

         return True and add to candidate list


getHPACapacityValue(hpaCapacityKey)

    return from List of HPACapacity.get(hpaCapacityKey)

Maintain HPA JSON Metadata file in Multicloud and OOF (Most of it is static information)


"HPA_feature_qualifications" : {
    "HPA_features" [
        {
            "HPA feature name": <"HPA feature name AKA HPA capability Name">
            "HPA capacity matching attributes" [
            "<Attribute Name>"
        }
        ],
    "HPA capacity check attribute": <"Attribute Name">
    ]
}
 
 
Example configuration file:
 
 
"HPA feature qualifications" :{
    "HPA features" : [
     {"PCIePassthrough", ["pciVendorid""pciDeviceID"], "pciCount"},
     {"basicCapabilites", ["numVirtualCPU"], "numVirtualCPU"},
     {"basicCapabilities", ["virtualMemSize"], "virtalMemSize:}
    ]
}



OOF - Generate the composite hpaCapacityKey

Examples of forming the composite key from the metadata file during capacity check.

HPAFeatureHPACapabilityAttributeComposite hpaCapacityKey
basicCapabilitiesnumVirtualCpubasicCapabilities_numVirtualCpu
basicCapabilitiesvirtualMemSizebasicCapabilities_virtualMemSize
pciePassthrough

pciVendorId

pciDeviceId

pciePassthrough_${pciVendorId}_${pciDeviceId}

${VAR} - replace with the hpa-capability-attribute-value

hugePagesmemoryPageSize

hugePages_memoryPageSize_4KB

hugePages_memoryPageSize_2MB

hugePages_memoryPageSize_1GB


  • No labels

15 Comments

  1. Srinivasa Addepalli Is there a way in Openstack to create relationship between ComputeNode and Flavors?

    1. No. There is no API to get hold of compute nodes from the flavors.

      1. Given that, how is all of this information going to be sourced?

        1. Hi Christina (@Christina Monteleone)

          Eric Multanen is working on this aspect in Multi-Cloud layer. We intend to have Prometheus based aggregation service that collects the platform specific information (via metrics).  Via alerts generated by aggregation service, it would glean information about the HPA capabilities of the compute node, capacity information of relevant HPA features (total and free) and health  of the HPA capability. And then it populates A&AI (if there is change in the information).

          Based on HPA capabilities, it will figure out which flavors the compute node belongs. Based on resource usage information, it figures out the HPA state information.

          On compute nodes, expectation is that node-exporter, collected, others such as IPMI exporter/cAdvisor are installed.

          Attn: Dileep Ranganathan


  2. Dileep Ranganathan

    In my view, we need to have following configuration file.

    "HPA feature qualifications" : {
        "HPA features" [
           {
           "HPA feature name": <"HPA feature name AKA HPA capability Name">
           "HPA capacity matching attributes" [
                "<Attribute Name>"
           }
           ],
           "HPA capacity check attribute": <"Attribute Name">
        ]
    }
    
    
    Example configuration file:
    
    
    "HPA feature qualifications" :{
        "HPA features" : [
         {"PCIePassthrough", ["pciVendorid", "pciDeviceID"], "pciCount"},
         {"basicCapabilites", ["numVirtualCPU"], "numVirtualCPU"},
         {"basicCapabilities", ["virtualMemSize"], "virtalMemSize:}
        ]
    }
  3. Dileep Ranganathan

    Based on our discussions, I guess you need to remove hpaCapacityKey from the HPA attributes for each HPA capability. Please update the main page accordingly.

    Srini


  4. The pserver node-type already exists in A&AI to represent a compute node - can that be reused instead of adding a new compute-node type?

      1. Can we add a edge between flavors and pserver? And also the Capacity Information (List of KV pair) to pserver?
      2. How/When is the Pserver (compute node) info populated in A&AI under cloud regions currently?


      1. I think adding the needed edges is fine.

        I'm also not clear on how pserver is currently sourced in ONAP. James Forsyth, do you know who the right contact to ask about this would be?

        1. Hi Christina, (Christina Monteleone)

          That is exact question we also had on who is sourcing pserver information and setting up the relations. 

          Also, we see pserver is beyond compute nodes, It seems to even represent physical network function devices too. This is based on relationships we see from PE, CE.

          We did not want to create any other issues by overloading pserver.

          Hence, we thought we will create compute node object.

          But, we are open to use pserver too. Let us know.

          Thanks

          Srini

          1. Physical network functions should be represented via the existing PNF object in A&AI. Overloading pserver for that purpose was never intended and is incorrect.

            1. Christina Monteleone,


              Thanks Christina for confirming that pServer is really intended to represent compute nodes, but not other physical network functions. 

              In that case, we need to see how we can  HPACapacityObject array in the pServer object. But few questions.

              First question:

              We see that pServers are defined at the global level today.  And we see there is some edge relationship from Cloud regions to pServers. Is that what is intended? Curious to know why pServers are required at the global level. 

              Another question:  So far, we have been thinking about creating compute nodes ourselves in the cloud-region. If we use pServers, we need to ensure that there is only one entity that creates pServers.  I understand that you asked the question to Jimmy to find out who is sourcing the pServers information today. I guess once we get that answer, we will need to figure out whether  we need to add 'pServer creation' logic in Multi-Cloud or check the current sourcing mechanism is good enough.  In pServer, there is quite a bit of information. Assuming that we need to add logic to create pServers, is it okay if we don't populate that information?

              Srini



              1. I don't see any need to nest pserver under cloud-region - that is what the edge between cloud-region and pserver already represents (pserver is LocatedIn a cloud-region). You create the cloud-region first, then when adding each pserver you include a relationship to that cloud-region in the relationship-list array of the PUT payload. This has the effect you want without requiring the client to know which cloud-region they are looking at when querying for a pserver by its hostname.

                As long as the required pserver properties can be populated we should be fine.


  5. Where can I find the ONAP reviewed and approved list of HPA Features/ HPA Capability Attributes?