Commit 233c2c91 authored by Jonathon Duerig's avatar Jonathon Duerig

Added optional key/value pairs as parameters for node_type as well. Added...

Added optional key/value pairs as parameters for node_type as well. Added 'bgpmux' as a virtualization_type on nodes.
parent 0936732a
......@@ -13,19 +13,22 @@
## Representation of a single node type
NodeTypeSpec = element node_type {
## Name of the type - will almost certainly not be unique
attribute type_name { text },
attribute type_name { text } &
## How many virtual nodes of this type this physical node can
## handle.
attribute type_slots { xsd:integer { minInclusive = "0" } | "unlimited" },
attribute type_slots { xsd:integer { minInclusive = "0" } | "unlimited" } &
##element unlimited { empty }?,
## A flag that indicates that this physical node *always*
## has this type - a node is only allowed to have one dynamic
## (ie. not flagged as static) type at a time, but any number
## of static types at a time
## element static { empty }?
attribute static { "true" }?
attribute static { "true" }? &
NodeTypeContents
}
NodeTypeContents = empty
## Link types are currently just a siple string. They will almost certainly
## have to get more complicated, for two reasons:
## First, I want to allow virtual links to specify more than one type, so
......
......@@ -3403,6 +3403,21 @@ sub GeniExperiment($)
return $experiment;
}
sub CreateTicket($)
{
my ($self) = @_;
return CreateRspec($self);
}
sub CreateManifest($)
{
my ($self) = @_;
return CreateRspec($self);
}
sub CreateRspec($)
{
}
# _Always_ make sure that this 1 is at the end of the file...
1;
......@@ -18,7 +18,7 @@ NodeContents =
# Each node has exactly one virtualization technology, which we simply
# enumerate here
attribute virtualization_type { "raw" | "trellis-vserver" |
"planetlab-vserver" | "emulab-vnode" }? &
"planetlab-vserver" | "emulab-vnode" | "bgpmux" }? &
# Node type list
NodeTypeList &
......@@ -45,12 +45,14 @@ NodeContents =
NodeTypeList = NodeTypeSpec+
NodeTypeContents &= TypeField*
LinkType = element link_type {
attribute name { text } &
LinkTypeField+
TypeField*
}
LinkTypeField = element field {
TypeField = element field {
attribute key { text } &
attribute value { text }
}
......
......@@ -34,6 +34,7 @@
<xs:enumeration value="trellis-vserver"/>
<xs:enumeration value="planetlab-vserver"/>
<xs:enumeration value="emulab-vnode"/>
<xs:enumeration value="bgpmux"/>
</xs:restriction>
</xs:simpleType>
</xs:attribute>
......@@ -108,7 +109,7 @@
<xs:element name="link_type">
<xs:complexType>
<xs:sequence>
<xs:element maxOccurs="unbounded" ref="rspec:field"/>
<xs:element minOccurs="0" maxOccurs="unbounded" ref="rspec:field"/>
</xs:sequence>
<xs:attribute name="name" use="required"/>
</xs:complexType>
......
......@@ -16,36 +16,45 @@
-->
<xs:element name="node_type">
<xs:complexType>
<xs:attribute name="type_name" use="required">
<xs:annotation>
<xs:documentation>Name of the type - will almost certainly not be unique</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="type_slots" use="required">
<xs:simpleType>
<xs:union>
<xs:complexContent>
<xs:extension base="rspec:NodeTypeContents">
<xs:attribute name="type_name" use="required">
<xs:annotation>
<xs:documentation>Name of the type - will almost certainly not be unique</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="type_slots" use="required">
<xs:simpleType>
<xs:restriction base="xs:integer">
<xs:minInclusive value="0"/>
</xs:restriction>
<xs:union>
<xs:simpleType>
<xs:restriction base="xs:integer">
<xs:minInclusive value="0"/>
</xs:restriction>
</xs:simpleType>
<xs:simpleType>
<xs:restriction base="xs:token">
<xs:enumeration value="unlimited"/>
</xs:restriction>
</xs:simpleType>
</xs:union>
</xs:simpleType>
</xs:attribute>
<xs:attribute name="static">
<xs:simpleType>
<xs:restriction base="xs:token">
<xs:enumeration value="unlimited"/>
<xs:enumeration value="true"/>
</xs:restriction>
</xs:simpleType>
</xs:union>
</xs:simpleType>
</xs:attribute>
<xs:attribute name="static">
<xs:simpleType>
<xs:restriction base="xs:token">
<xs:enumeration value="true"/>
</xs:restriction>
</xs:simpleType>
</xs:attribute>
</xs:attribute>
</xs:extension>
</xs:complexContent>
</xs:complexType>
</xs:element>
<xs:complexType name="NodeTypeContents">
<xs:sequence>
<xs:element minOccurs="0" maxOccurs="unbounded" ref="rspec:field"/>
</xs:sequence>
</xs:complexType>
<xs:group name="LinkTypeSpec">
<xs:sequence>
<xs:element name="link_type">
......
......@@ -27,6 +27,7 @@
<xs:enumeration value="trellis-vserver"/>
<xs:enumeration value="planetlab-vserver"/>
<xs:enumeration value="emulab-vnode"/>
<xs:enumeration value="bgpmux"/>
</xs:restriction>
</xs:simpleType>
</xs:attribute>
......@@ -111,7 +112,7 @@
<xs:element name="link_type">
<xs:complexType>
<xs:sequence>
<xs:element maxOccurs="unbounded" ref="rspec:field"/>
<xs:element minOccurs="0" maxOccurs="unbounded" ref="rspec:field"/>
</xs:sequence>
<xs:attribute name="name" use="required"/>
</xs:complexType>
......
......@@ -16,36 +16,45 @@
-->
<xs:element name="node_type">
<xs:complexType>
<xs:attribute name="type_name" use="required">
<xs:annotation>
<xs:documentation>Name of the type - will almost certainly not be unique</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="type_slots" use="required">
<xs:simpleType>
<xs:union>
<xs:complexContent>
<xs:extension base="rspec:NodeTypeContents">
<xs:attribute name="type_name" use="required">
<xs:annotation>
<xs:documentation>Name of the type - will almost certainly not be unique</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="type_slots" use="required">
<xs:simpleType>
<xs:restriction base="xs:integer">
<xs:minInclusive value="0"/>
</xs:restriction>
<xs:union>
<xs:simpleType>
<xs:restriction base="xs:integer">
<xs:minInclusive value="0"/>
</xs:restriction>
</xs:simpleType>
<xs:simpleType>
<xs:restriction base="xs:token">
<xs:enumeration value="unlimited"/>
</xs:restriction>
</xs:simpleType>
</xs:union>
</xs:simpleType>
</xs:attribute>
<xs:attribute name="static">
<xs:simpleType>
<xs:restriction base="xs:token">
<xs:enumeration value="unlimited"/>
<xs:enumeration value="true"/>
</xs:restriction>
</xs:simpleType>
</xs:union>
</xs:simpleType>
</xs:attribute>
<xs:attribute name="static">
<xs:simpleType>
<xs:restriction base="xs:token">
<xs:enumeration value="true"/>
</xs:restriction>
</xs:simpleType>
</xs:attribute>
</xs:attribute>
</xs:extension>
</xs:complexContent>
</xs:complexType>
</xs:element>
<xs:complexType name="NodeTypeContents">
<xs:sequence>
<xs:element minOccurs="0" maxOccurs="unbounded" ref="rspec:field"/>
</xs:sequence>
</xs:complexType>
<xs:group name="LinkTypeSpec">
<xs:sequence>
<xs:element name="link_type">
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment