Mailing List Archive

XSDL schemas for Xen virtual machine configurations
Please pardon my ignorance if this had already been discussed.

Has there been any work on standardizing schemas for Xen virtual machine
configurations? I really like XSDL schemas instead of DTD's.
Regardless, I'd like to have schemas that

(1) Indicate which version of Xen they require.
(2) Enumerate exactly which options are available.

Peace.
Andrew




_______________________________________________
xen-api mailing list
xen-api@lists.xensource.com
http://lists.xensource.com/cgi-bin/mailman/listinfo/xen-api
Re: XSDL schemas for Xen virtual machine configurations [ In reply to ]
On Tue, Aug 01, 2006 at 03:21:06PM -0400, Andrew D. Ball wrote:
> Please pardon my ignorance if this had already been discussed.
>
> Has there been any work on standardizing schemas for Xen virtual machine
> configurations? I really like XSDL schemas instead of DTD's.
> Regardless, I'd like to have schemas that
>
> (1) Indicate which version of Xen they require.
> (2) Enumerate exactly which options are available.

Which may be extremely hard to express with XSD (if not impossible) due
to the lack of support for co-occurence constaints (things like "you can
have a vmx children to a domain node only if there is no kernel attribute
on the parent" are impossible top express with XSD, making versionning
near impossible). I suggest reading about Relax-NG
http://relaxng.org/
http://relaxng.org/tutorial-20011203.html

Daniel

--
Daniel Veillard | Red Hat http://redhat.com/
veillard@redhat.com | libxml GNOME XML XSLT toolkit http://xmlsoft.org/
http://veillard.com/ | Rpmfind RPM search engine http://rpmfind.net/

_______________________________________________
xen-api mailing list
xen-api@lists.xensource.com
http://lists.xensource.com/cgi-bin/mailman/listinfo/xen-api
Re: XSDL schemas for Xen virtual machine configurations [ In reply to ]
On Tue, Aug 01, 2006 at 03:21:06PM -0400, Andrew D. Ball wrote:

> Please pardon my ignorance if this had already been discussed.
>
> Has there been any work on standardizing schemas for Xen virtual machine
> configurations? I really like XSDL schemas instead of DTD's.
> Regardless, I'd like to have schemas that
>
> (1) Indicate which version of Xen they require.
> (2) Enumerate exactly which options are available.

As far as I know, there's no-one working on XSDL schemas for this, no. I did
intend to put together a DTD, though I've not done it yet. I've no idea
whether XSDL schemas or other technologies would be appropriate, though
Daniel's reply suggests that there's doubt, at least ;-)

Perhaps you could kick this off, if you are interested?

Ewan.

_______________________________________________
xen-api mailing list
xen-api@lists.xensource.com
http://lists.xensource.com/cgi-bin/mailman/listinfo/xen-api
Re: XSDL schemas for Xen virtual machine configurations [ In reply to ]
On Wed, Aug 02, 2006 at 09:21:09AM +0100, Ewan Mellor wrote:
> On Tue, Aug 01, 2006 at 03:21:06PM -0400, Andrew D. Ball wrote:
>
> > Please pardon my ignorance if this had already been discussed.
> >
> > Has there been any work on standardizing schemas for Xen virtual machine
> > configurations? I really like XSDL schemas instead of DTD's.
> > Regardless, I'd like to have schemas that
> >
> > (1) Indicate which version of Xen they require.
> > (2) Enumerate exactly which options are available.
>
> As far as I know, there's no-one working on XSDL schemas for this, no. I did
> intend to put together a DTD, though I've not done it yet. I've no idea
> whether XSDL schemas or other technologies would be appropriate, though
> Daniel's reply suggests that there's doubt, at least ;-)

Well I was mostly reacting to "I really like XSDL schemas" :-)
It definitely allows a better checking of the input documents, but
trying to make one XSD handle evolution and versioning is in practice
relatively hard.

> Perhaps you could kick this off, if you are interested?

I have an item about this in libvirt TODO. In my experience it may
less be useful for validating input at this point (since the format is likely
to evolve) than as a way to document relatively thorougthly what one may
find in the XML instance (and hence write the appropriate code handling all
cases). Sometimes the mapping between the predefined schemas data types
and what is the actually acceptable values is where the real usefulness
of the check, examples:

- with DTD you can say a domain has one memory and one name children
- with XSD you may refine this stating that the content of memory is
a positive integer and the content of name is a string
- a better schemas would also check values to make sure memory is at least
4Mbytes and less than 16GB and that the name matches [0-9a-zA-Z]* to
avoid problems

Now the amount of effort you take to build a really good schemas is worth it
only if the instances content is relatively stable, and if many people use it
as it's harder to define than with a normal programming language.

My 2 euro cents,

Daniel

--
Daniel Veillard | Red Hat http://redhat.com/
veillard@redhat.com | libxml GNOME XML XSLT toolkit http://xmlsoft.org/
http://veillard.com/ | Rpmfind RPM search engine http://rpmfind.net/

_______________________________________________
xen-api mailing list
xen-api@lists.xensource.com
http://lists.xensource.com/cgi-bin/mailman/listinfo/xen-api
Re: XSDL schemas for Xen virtual machine configurations [ In reply to ]
Cool!

You're most welcome to kick this off which whichever type of schema you
think is appropriate. I think [without lots of experience to back it
up, mind you] that something simple would be fine for now, leaving the
more complicated contraints to domain logic.

My [less valuable] 2 US cents.
Peace.
Andrew

On Wed, 2006-08-02 at 05:04 -0400, Daniel Veillard wrote:
> On Wed, Aug 02, 2006 at 09:21:09AM +0100, Ewan Mellor wrote:
> > On Tue, Aug 01, 2006 at 03:21:06PM -0400, Andrew D. Ball wrote:
> >
> > > Please pardon my ignorance if this had already been discussed.
> > >
> > > Has there been any work on standardizing schemas for Xen virtual machine
> > > configurations? I really like XSDL schemas instead of DTD's.
> > > Regardless, I'd like to have schemas that
> > >
> > > (1) Indicate which version of Xen they require.
> > > (2) Enumerate exactly which options are available.
> >
> > As far as I know, there's no-one working on XSDL schemas for this, no. I did
> > intend to put together a DTD, though I've not done it yet. I've no idea
> > whether XSDL schemas or other technologies would be appropriate, though
> > Daniel's reply suggests that there's doubt, at least ;-)
>
> Well I was mostly reacting to "I really like XSDL schemas" :-)
> It definitely allows a better checking of the input documents, but
> trying to make one XSD handle evolution and versioning is in practice
> relatively hard.
>
> > Perhaps you could kick this off, if you are interested?
>
> I have an item about this in libvirt TODO. In my experience it may
> less be useful for validating input at this point (since the format is likely
> to evolve) than as a way to document relatively thorougthly what one may
> find in the XML instance (and hence write the appropriate code handling all
> cases). Sometimes the mapping between the predefined schemas data types
> and what is the actually acceptable values is where the real usefulness
> of the check, examples:
>
> - with DTD you can say a domain has one memory and one name children
> - with XSD you may refine this stating that the content of memory is
> a positive integer and the content of name is a string
> - a better schemas would also check values to make sure memory is at least
> 4Mbytes and less than 16GB and that the name matches [0-9a-zA-Z]* to
> avoid problems
>
> Now the amount of effort you take to build a really good schemas is worth it
> only if the instances content is relatively stable, and if many people use it
> as it's harder to define than with a normal programming language.
>
> My 2 euro cents,
>
> Daniel
>


_______________________________________________
xen-api mailing list
xen-api@lists.xensource.com
http://lists.xensource.com/cgi-bin/mailman/listinfo/xen-api
Re: XSDL schemas for Xen virtual machine configurations [ In reply to ]
On 02/08/06 09:57 -0400, Andrew D. Ball wrote:
>Cool!
>
>You're most welcome to kick this off which whichever type of schema you
>think is appropriate. I think [without lots of experience to back it
>up, mind you] that something simple would be fine for now, leaving the
>more complicated contraints to domain logic.

Please don't ignore the DMTF modelling work that is going on right now. CIM
technology is not elegant but standard xml schemata are truly horrid - there
are no elegant options.

CIM schemata are very good a expressing conditions and relationships, despite
their clumsy notation.

Mike

_______________________________________________
xen-api mailing list
xen-api@lists.xensource.com
http://lists.xensource.com/cgi-bin/mailman/listinfo/xen-api
Re: Re: XSDL schemas for Xen virtual machine configurations [ In reply to ]
Well, I was going to keep quiet rather than risk forever being labelled
(and dismissed?) as a "CIM bigot", but ... :-)

As Mike implies, there is today already a "pseudo-standard" XML based
format for fully describing a virtual system configuration, namely the
array of CIM_SettingData that is passed into the DefineVirtualSystem()
extrinsic method in the DMTF System Virtualization profile. Basically, this
contains all the important data describing what you want in your VM, shoved
into a CIM-XML extrinsic method call. The *actual* settings of the eventual
new VM may differ somewhat, since the virtualization platform may apply
some internal defaults, etc, but you still basically end up with a set of
CIM_SettingData objects that fully describe the VM, all of which can be
translated in a well-defined manner to CIM-XML. Whilst we don't pass in any
associations defining structural relations between the components of the
new VM, these are generated as part of the DefineVirtualSystem process to
tie things together and exist as internal CIM objects (aka CIM_Dependency
subclasses) and have a well-defined CIM-XML representation too.


I'm not suggesting that we must adopt CIM-XML because it is undoubtedly the
best format to persist DomU config data - it probably isn't the 'best' -
but the reality is that we effectively have all the data in this specific
XML format already, independent of anything else, by virtue of the CIM mgmt
stuff. And by definition, we - Xen CIM folk - are going to have to make
sure everything we need to express for a DomU config can be expressed via
CIM classes, and hence representable in CIM-XML, in order for us to do
basic CIM-based lifecycle management of Xen; ie we're already effectively
having to invent this wheel, albeit primarily for our CIM mgmt! :-)

Just something to keep in mind.

- Gareth

Dr. Gareth S. Bestor
IBM Linux Technology Center
M/S DES2-01
15300 SW Koll Parkway, Beaverton, OR 97006
503-578-3186, T/L 775-3186, Fax 503-578-3186




ncmike@us.ltcfwd.
linux.ibm.com
Sent by: To
xen-api-bounces@l aball@us.ltcfwd.linux.ibm.com
ists.xensource.co cc
m xen-api@lists.xensource.com
Subject
[Xen-API] Re: XSDL schemas for Xen
08/02/06 07:30 AM virtual machine configurations










On 02/08/06 09:57 -0400, Andrew D. Ball wrote:
>Cool!
>
>You're most welcome to kick this off which whichever type of schema you
>think is appropriate. I think [without lots of experience to back it
>up, mind you] that something simple would be fine for now, leaving the
>more complicated contraints to domain logic.

Please don't ignore the DMTF modelling work that is going on right now. CIM

technology is not elegant but standard xml schemata are truly horrid -
there
are no elegant options.

CIM schemata are very good a expressing conditions and relationships,
despite
their clumsy notation.

Mike

_______________________________________________
xen-api mailing list
xen-api@lists.xensource.com
http://lists.xensource.com/cgi-bin/mailman/listinfo/xen-api
Re: Re: XSDL schemas for Xen virtual machine configurations [ In reply to ]
Cool! Then it should be easy to persist a domU's CIM representation
using whatever persistence layer one wants to use, right?

Peace.
Andrew
On Thu, 2006-08-03 at 08:40 -0700, Gareth S Bestor wrote:
> Well, I was going to keep quiet rather than risk forever being
> labelled (and dismissed?) as a "CIM bigot", but ... :-)
>
> As Mike implies, there is today already a "pseudo-standard" XML based
> format for fully describing a virtual system configuration, namely the
> array of CIM_SettingData that is passed into the DefineVirtualSystem()
> extrinsic method in the DMTF System Virtualization profile. Basically,
> this contains all the important data describing what you want in your
> VM, shoved into a CIM-XML extrinsic method call. The *actual* settings
> of the eventual new VM may differ somewhat, since the virtualization
> platform may apply some internal defaults, etc, but you still
> basically end up with a set of CIM_SettingData objects that fully
> describe the VM, all of which can be translated in a well-defined
> manner to CIM-XML. Whilst we don't pass in any associations defining
> structural relations between the components of the new VM, these are
> generated as part of the DefineVirtualSystem process to tie things
> together and exist as internal CIM objects (aka CIM_Dependency
> subclasses) and have a well-defined CIM-XML representation too.
>
>
> I'm not suggesting that we must adopt CIM-XML because it is
> undoubtedly the best format to persist DomU config data - it probably
> isn't the 'best' - but the reality is that we effectively have all the
> data in this specific XML format already, independent of anything
> else, by virtue of the CIM mgmt stuff. And by definition, we - Xen CIM
> folk - are going to have to make sure everything we need to express
> for a DomU config can be expressed via CIM classes, and hence
> representable in CIM-XML, in order for us to do basic CIM-based
> lifecycle management of Xen; ie we're already effectively having to
> invent this wheel, albeit primarily for our CIM mgmt! :-)
>
> Just something to keep in mind.
>
> - Gareth
>
> Dr. Gareth S. Bestor
> IBM Linux Technology Center
> M/S DES2-01
> 15300 SW Koll Parkway, Beaverton, OR 97006
> 503-578-3186, T/L 775-3186, Fax 503-578-3186
>
> Inactive hide details for
> ncmike@us.ltcfwd.linux.ibm.comncmike@us.ltcfwd.linux.ibm.com
>
>
> ncmike@us.ltcfwd.linux.ibm.com
> Sent by: xen-api-bounces@lists.xensource.com
>
> 08/02/06 07:30 AM
>
>
> To
>
> aball@us.ltcfwd.linux.ibm.com
>
> cc
>
> xen-
> api@lists.xensource.com
>
> Subject
>
> [Xen-API] Re:
> XSDL schemas for
> Xen virtual
> machine
> configurations
>
>
>
> On 02/08/06 09:57 -0400, Andrew D. Ball wrote:
> >Cool!
> >
> >You're most welcome to kick this off which whichever type of schema
> you
> >think is appropriate. I think [.without lots of experience to back it
> >up, mind you] that something simple would be fine for now, leaving
> the
> >more complicated contraints to domain logic.
>
> Please don't ignore the DMTF modelling work that is going on right
> now. CIM
> technology is not elegant but standard xml schemata are truly horrid -
> there
> are no elegant options.
>
> CIM schemata are very good a expressing conditions and relationships,
> despite
> their clumsy notation.
>
> Mike
>
> _______________________________________________
> xen-api mailing list
> xen-api@lists.xensource.com
> http://lists.xensource.com/cgi-bin/mailman/listinfo/xen-api
>
>
>


_______________________________________________
xen-api mailing list
xen-api@lists.xensource.com
http://lists.xensource.com/cgi-bin/mailman/listinfo/xen-api
Re: Re: XSDL schemas for Xen virtual machine configurations [ In reply to ]
The CIM-XML data is basically there for the plucking, if anybody (else)
wants it. :-) And a relatively simple CIM client request will get it for
you. If/when/where/how it is persisted elsewhere (as a file?) and in what
format is pretty much up to y'all.

- Gareth

Dr. Gareth S. Bestor
IBM Linux Technology Center
M/S DES2-01
15300 SW Koll Parkway, Beaverton, OR 97006
503-578-3186, T/L 775-3186, Fax 503-578-3186




aball@us.ltcfwd.l
inux.ibm.com
To
08/03/06 11:53 AM Gareth S Bestor/Beaverton/IBM@IBMUS
cc
Ewan Mellor <ewan@xensource.com>,
veillard@redhat.com,
xen-api@lists.xensource.com,
ncmike@us.ltcfwd.linux.ibm.com
Subject
Re: [Xen-API] Re: XSDL schemas for
Xen virtual machine
configurations










Cool! Then it should be easy to persist a domU's CIM representation
using whatever persistence layer one wants to use, right?

Peace.
Andrew
On Thu, 2006-08-03 at 08:40 -0700, Gareth S Bestor wrote:
> Well, I was going to keep quiet rather than risk forever being
> labelled (and dismissed?) as a "CIM bigot", but ... :-)
>
> As Mike implies, there is today already a "pseudo-standard" XML based
> format for fully describing a virtual system configuration, namely the
> array of CIM_SettingData that is passed into the DefineVirtualSystem()
> extrinsic method in the DMTF System Virtualization profile. Basically,
> this contains all the important data describing what you want in your
> VM, shoved into a CIM-XML extrinsic method call. The *actual* settings
> of the eventual new VM may differ somewhat, since the virtualization
> platform may apply some internal defaults, etc, but you still
> basically end up with a set of CIM_SettingData objects that fully
> describe the VM, all of which can be translated in a well-defined
> manner to CIM-XML. Whilst we don't pass in any associations defining
> structural relations between the components of the new VM, these are
> generated as part of the DefineVirtualSystem process to tie things
> together and exist as internal CIM objects (aka CIM_Dependency
> subclasses) and have a well-defined CIM-XML representation too.
>
>
> I'm not suggesting that we must adopt CIM-XML because it is
> undoubtedly the best format to persist DomU config data - it probably
> isn't the 'best' - but the reality is that we effectively have all the
> data in this specific XML format already, independent of anything
> else, by virtue of the CIM mgmt stuff. And by definition, we - Xen CIM
> folk - are going to have to make sure everything we need to express
> for a DomU config can be expressed via CIM classes, and hence
> representable in CIM-XML, in order for us to do basic CIM-based
> lifecycle management of Xen; ie we're already effectively having to
> invent this wheel, albeit primarily for our CIM mgmt! :-)
>
> Just something to keep in mind.
>
> - Gareth
>
> Dr. Gareth S. Bestor
> IBM Linux Technology Center
> M/S DES2-01
> 15300 SW Koll Parkway, Beaverton, OR 97006
> 503-578-3186, T/L 775-3186, Fax 503-578-3186
>
> Inactive hide details for
> ncmike@us.ltcfwd.linux.ibm.comncmike@us.ltcfwd.linux.ibm.com
>
>
> ncmike@us.ltcfwd.linux.ibm.com
> Sent by:
xen-api-bounces@lists.xensource.com
>
> 08/02/06 07:30 AM
>
>
> To
>
> aball@us.ltcfwd.linux.ibm.com
>
> cc
>
> xen-
> api@lists.xensource.com
>
> Subject
>
> [Xen-API] Re:
> XSDL schemas for
> Xen virtual
> machine
> configurations
>
>
>
> On 02/08/06 09:57 -0400, Andrew D. Ball wrote:
> >Cool!
> >
> >You're most welcome to kick this off which whichever type of schema
> you
> >think is appropriate. I think [.without lots of experience to back it
> >up, mind you] that something simple would be fine for now, leaving
> the
> >more complicated contraints to domain logic.
>
> Please don't ignore the DMTF modelling work that is going on right
> now. CIM
> technology is not elegant but standard xml schemata are truly horrid -
> there
> are no elegant options.
>
> CIM schemata are very good a expressing conditions and relationships,
> despite
> their clumsy notation.
>
> Mike
>
> _______________________________________________
> xen-api mailing list
> xen-api@lists.xensource.com
> http://lists.xensource.com/cgi-bin/mailman/listinfo/xen-api
>
>
>