occi xml representation
TRANSCRIPT
![Page 1: OCCI XML representation](https://reader037.vdocuments.us/reader037/viewer/2022100606/55a1f1551a28ab4e788b458a/html5/thumbnails/1.jpg)
1This document is licensed under a Creative Commons Attribution 3.0 Unported License.
Madrid, September 18th, 2013 Jean Parpaillon – SilkanIain James Marshall – Prologue
Jonathan Custance - OnApp
OCCI XML representation
![Page 2: OCCI XML representation](https://reader037.vdocuments.us/reader037/viewer/2022100606/55a1f1551a28ab4e788b458a/html5/thumbnails/2.jpg)
22This document is licensed under a Creative Commons Attribution 3.0 Unported License.
September 18th, 2013 Cloud Interoperability Week
Background
✔ CompatibleOne : an open source cloud brokering platform
✔ Based on OCCI✔ With extensions: manifest, configuration, user, security, etc.
✔ Use XML for✔ Storage✔ Validation: categories described as XML schema (XSD)
![Page 3: OCCI XML representation](https://reader037.vdocuments.us/reader037/viewer/2022100606/55a1f1551a28ab4e788b458a/html5/thumbnails/3.jpg)
33This document is licensed under a Creative Commons Attribution 3.0 Unported License.
September 18th, 2013 Cloud Interoperability Week
Current extensions specs
✔ Free text + UML schemas✔ Attributes types: string, numbers✔ Attributes multiplicity: required, optional✔ No attributes default value
![Page 4: OCCI XML representation](https://reader037.vdocuments.us/reader037/viewer/2022100606/55a1f1551a28ab4e788b458a/html5/thumbnails/4.jpg)
4
Objectives
Formal specifications(machine readable, including doc)
«Design once, implement everywhere »
Implementation generation
Attributes types specifications
RangePatternsComplex types
Rendering for XML based protocol (XMPP)
![Page 5: OCCI XML representation](https://reader037.vdocuments.us/reader037/viewer/2022100606/55a1f1551a28ab4e788b458a/html5/thumbnails/5.jpg)
55This document is licensed under a Creative Commons Attribution 3.0 Unported License.
September 18th, 2013 Cloud Interoperability Week
XML reminder
✔ Formal constraint description: XML schemas✔ Validation
✔ Transformation✔ XSLT: XML to XML, XML to text
✔ Query✔ XPATH
✔ Parsing ✔ Tree based, event based, ...
![Page 6: OCCI XML representation](https://reader037.vdocuments.us/reader037/viewer/2022100606/55a1f1551a28ab4e788b458a/html5/thumbnails/6.jpg)
66This document is licensed under a Creative Commons Attribution 3.0 Unported License.
September 18th, 2013 Cloud Interoperability Week
XML schema proposal (1)
✔ An XML schema to describe OCCI types✔ Kind, Mixin, Action, Resource, Link
✔ Top-level elements: ✔ Extension (kind+, mixin+): for extensions✔ Objects (kind+, mixin+, action+, resource+, link+): for
rendering
![Page 7: OCCI XML representation](https://reader037.vdocuments.us/reader037/viewer/2022100606/55a1f1551a28ab4e788b458a/html5/thumbnails/7.jpg)
7
OCCI type description
<xs:complexType name="kindType"> <xs:sequence> <xs:element name="rel" type="occi:relatedType" minOccurs="1"
maxOccurs="1" /> <xs:element name="attribute" type="occi:attributeSpecType"
minOccurs="0" maxOccurs="unbounded" /> <xs:element name="action" type="occi:actionSpecType"
minOccurs="0" maxOccurs="unbounded" /> </xs:sequence> <xs:attributeGroup ref="occi:categoryGroup"></xs:attributeGroup> <xs:attribute name="location" type="xs:anyURI"></xs:attribute></xs:complexType>
<occi:kind term="network" scheme="http://schemas.ogf.org/occi/core#"title="Network Resource">
<occi:rel scheme="http://schemas.ogf.org/occi/core#" term="resource" /> <occi:attribute name="occi.network.vlan" type="occi:vlanType" /> <occi:attribute name="occi.network.label" type="xs:string" /> <occi:attribute name="occi.network.state" type="xs:string"
immutable="true" use="required" default="inactive"> <xs:simpleType> <xs:restriction base="xs:string"> <xs:enumeration value="active" /> <xs:enumeration value="inactive" /> </xs:restriction> </xs:simpleType> </occi:attribute> <occi:action scheme="http://schemas.ogf.org/occi/core/network#"
term="up"></occi:action> <occi:action scheme="http://schemas.ogf.org/occi/core/network#"
term="down"></occi:action></occi:kind>
OCCI types schema
OCCI type description
![Page 8: OCCI XML representation](https://reader037.vdocuments.us/reader037/viewer/2022100606/55a1f1551a28ab4e788b458a/html5/thumbnails/8.jpg)
8
OCCI entity rendering
<occi:link id="urn:uuid:c78774ae-264b-405b-b5ae-db6d2486ff8d"source="/compute/996ad860-2a9a-504f-8861-aeafd0b2ae29" target="/network/1cbc522b-eff3-4ea7-ab53-d91ad7c34b7f">
<occi:kind term="networkinterface" scheme="http://schemas.ogf.org/occi/infrastructure#" /> <occi:mixin term="ipnetworkinterface"
scheme="http://schemas.ogf.org/occi/infrastructure/networkinterface#" /> <occi:attribute name="occi.infrastructure.networkinterface.interface" value="eth0" /> <occi:attribute name="occi.infrastructure.networkinterface.mac" value="00:ae:ff:23:43:12" /> <occi:attribute name="occi.infrastructure.networkinterface.address" value="192.168.0.100" /> <occi:attribute name="occi.infrastructure.networkinterface.gateway" value="192.168.0.1" /> <occi:attribute name="occi.infrastructure.networkinterface.allocation" value="dynamic" /> <occi:action term="up"
scheme="http://schemas.ogf.org/occi/infrastructure/networkinterface/action#" /></occi:link>
Link entity rendering
w/ mixin
![Page 9: OCCI XML representation](https://reader037.vdocuments.us/reader037/viewer/2022100606/55a1f1551a28ab4e788b458a/html5/thumbnails/9.jpg)
99This document is licensed under a Creative Commons Attribution 3.0 Unported License.
September 18th, 2013 Cloud Interoperability Week
XML schema proposal (2)
✔ Attribute types: inherits XSD typing✔ 44 base types: decimal, string, date, etc.✔ Type extension
✔ Integer + 'undefined'
✔ Type restriction✔ String pattern✔ Number range
![Page 10: OCCI XML representation](https://reader037.vdocuments.us/reader037/viewer/2022100606/55a1f1551a28ab4e788b458a/html5/thumbnails/10.jpg)
10
OCCI attribute type
<xs:simpleType name="vlanType"> <xs:restriction base="xs:integer"> <xs:minInclusive value="0"></xs:minInclusive> <xs:maxInclusive value="4095"></xs:maxInclusive> </xs:restriction></xs:simpleType>
<xs:simpleType name="mac802"> <xs:restriction base="xs:string"> <xs:pattern value="[\da-fA-F]{2}(\:[\da-fA-F]{2})5}" /> </xs:restriction></xs:simpleType>
802.1q VLAN type
MAC Address
![Page 11: OCCI XML representation](https://reader037.vdocuments.us/reader037/viewer/2022100606/55a1f1551a28ab4e788b458a/html5/thumbnails/11.jpg)
1111This document is licensed under a Creative Commons Attribution 3.0 Unported License.
September 18th, 2013 Cloud Interoperability Week
That's all !
✔ Please comment, amend... implement✔ Resources
✔ CompatibleOne project: http://www.compatibleone.org/✔ Updated XML schemas and examples:
http://github.com/jeanparpaillon/occi-schemas✔ E-mail: [email protected]
![Page 12: OCCI XML representation](https://reader037.vdocuments.us/reader037/viewer/2022100606/55a1f1551a28ab4e788b458a/html5/thumbnails/12.jpg)
12This document is licensed under a Creative Commons Attribution 3.0 Unported License.
Thanks !