geni.rspec.pgad

class AdInterface(name)[source]

Wrapper object for a Node Interface in a GENIv3 Advertisement.

component_id

Component ID URN

Type

str

role

The resource role of this interface (typically “control” or “experimental”). None if unset.

Type

str

name

Friendly name for this interface, None if unset.

Type

str

property text
class AdNode[source]

Wrapper object for a Node in a GENIv3 advertisement.

Note

In general this object is created on-demand through Advertisement objects, but you can load this object from a Node XML element by using the _fromdom classmethod.

Attributes:

component_id (str): Component ID URN component_manager_id (str): Component Manager ID URN name (str): Friendly name provided by aggregate for this resource. exclusive (bool): True if a node can be reserved as a raw PC available (bool): Whether this node is currently available for reservations hardware_types (dict): Mapping of { type_name : type_slots, … } sliver_types (set): Supported sliver type images (dict): Mapping of { sliver_type : [supported_image_name, …], … } shared (bool): True if currently being used as a shared resource interfaces (list): List of AdInterface objects for this Node location (AdLocation): None if not available ram (int): Currently available system RAM in megabytes. None if not available. cpu (int): Maximum Per-core CPU speed in Mhz. None if not available.

property text
class AdSharedVLAN[source]
class Advertisement(path=None, xml=None)[source]

Wrapper object for a GENIv3 XML advertisement.

Only one argument can be supplied (if both are provided path will be used)

Parameters
  • path (str, unicode) – Path to XML file on disk containing an advertisement

  • xml (str, unicode) – In-memory XML byte stream containing an advertisement

property images

An iterable of the unique images found in this advertisement.

An indexable iterator over the AdLink objects in this advertisement.

property nodes

An indexable iterator over the AdNode objects in this advertisement.

property routable_addresses

A RoutableAddresses object containing the number of configured and available publicly routable IP addresses at this site.

property shared_vlans

An indexable iterator of the shared vlan names found in this advertisement.

property stitchinfo

Reference to the stitching info in the manifest, if present.

property text

Advertisement XML contents as a string, formatted with whitespace for easier reading.

writeXML(path)[source]

Write the current advertisement as an XML file that contains an rspec in the format returned by the aggregate.

class Image[source]
class Location[source]
class RoutableAddresses[source]
property capacity