ia64/xen-unstable

changeset 12115:53b8f2b74ab2

[XENAPI] Adding some rudimentary documentation about what has changed.

Signed-off-by: Alastair Tse <atse@xensource.com>
author Alastair Tse <atse@xensource.com>
date Fri Oct 06 18:01:08 2006 +0100 (2006-10-06)
parents f5912c42fbc3
children 9e0b024a1696
files tools/python/scripts/README.lifecycle
line diff
     1.1 --- /dev/null	Thu Jan 01 00:00:00 1970 +0000
     1.2 +++ b/tools/python/scripts/README.lifecycle	Fri Oct 06 18:01:08 2006 +0100
     1.3 @@ -0,0 +1,136 @@
     1.4 +Xend Lifecycle/XenAPI Implementation Changes
     1.5 +============================================
     1.6 +
     1.7 +Summary of what has changed in this branch of Xend:
     1.8 +
     1.9 +Managed Domains
    1.10 +---------------
    1.11 +
    1.12 +The concept of managed domains is that Xend now has the ability to
    1.13 +manage the lifecycle of a domain from when it is created to being
    1.14 +shutdown. 
    1.15 +
    1.16 +XendDomain
    1.17 +~~~~~~~~~~
    1.18 +
    1.19 +In order to support managed domains, XendDomain has been modified to
    1.20 +keep the configuration in /var/lib/xend/domains/.
    1.21 +
    1.22 +The configuration is stored in SXP format so that it can be easily
    1.23 +loaded by the current Xend. In the future, we may switch to an XML
    1.24 +format similar to how XenAPI defines a VM configuration.
    1.25 +
    1.26 +TODO: There are still places where the device configuration or VM
    1.27 +configuration can be altered but the managed domain does not save it.
    1.28 +
    1.29 +XendDomainInfo
    1.30 +~~~~~~~~~~~~~~
    1.31 +
    1.32 +XendDomainInfo has changed to support this mode of operation,
    1.33 +especially with domain construction and assumptions about the domain
    1.34 +when it shuts down.
    1.35 +
    1.36 +All configuration option parsing and validation has been moved from
    1.37 +XendDomainInfo to XendConfig. The purpose is so that we can abstract
    1.38 +away the knowledge of SXP in XendDomainInfo. The goal is to do away
    1.39 +with the bulky way of accessing SXP in Xend and moving that all to a
    1.40 +more pythonic interface.
    1.41 +
    1.42 +The DevController stuff at the end of XendDomainInfo has also been
    1.43 +moved to XendDevices because now it is needed in both XendConfig and
    1.44 +XendDomainInfo.
    1.45 +
    1.46 +Many of the constants are moved to XendConstants which reduces the
    1.47 +amount of recursive or scoped imports that occur in the code.
    1.48 +
    1.49 +XendConfig
    1.50 +~~~~~~~~~~
    1.51 +
    1.52 +XendConfig is the beginnings of an interface for configuration options
    1.53 +so that other parts of Xend do not need to know what format the
    1.54 +configuration in. It can accept configuration passed in as parsed SXP
    1.55 +format, python filename or a Xen API struct.
    1.56 +
    1.57 +It is a subclass of a python dictionary, and hence access to its
    1.58 +functions are via the __getitem__ accessor. 
    1.59 +
    1.60 +TODO: Define a proper interface to the XendConfig which is based on
    1.61 +either the Xen API or some other flexible format.
    1.62 +
    1.63 +XMLRPCServer
    1.64 +~~~~~~~~~~~~
    1.65 +
    1.66 +Changes to the busy loop in here and SrvServer so that the daemon
    1.67 +shuts down cleanly. This also allows us to catch the shutdown and
    1.68 +perform maintanence tasks on the domains. 
    1.69 +
    1.70 +Replacing xendomains init.d script 
    1.71 +==================================
    1.72 +
    1.73 +Some work has gone into catching Xend's shutdown so that we can do the
    1.74 +same tasks that xendomains init.d script does but natively in Xend.
    1.75 +
    1.76 +For instance, a new configuration option, 'on_xend_start' and
    1.77 +'on_xend_stop' will allow domains that are managed by Xend to start up
    1.78 +when Xend starts, and correspondingly stop when Xend stops.
    1.79 +
    1.80 +Xen API
    1.81 +=======
    1.82 +
    1.83 +The new Xen API gives a standard interface to creating, configuring,
    1.84 +controlling and destroying VMs and the virtual devices that belong to
    1.85 +it.
    1.86 +
    1.87 +It also introduces the concept of Storage Repositories (SR) which are
    1.88 +factories for creating disk images.
    1.89 +
    1.90 +XendDomain
    1.91 +~~~~~~~~~~
    1.92 +
    1.93 +XendDomain has now separated the section for the Legacy XM XMLRPC API
    1.94 +and the new Xen API.
    1.95 +
    1.96 +Since many things have a UUID, these are stored and represented as
    1.97 +close to the existing configuration. 
    1.98 +
    1.99 +XendDomainInfo
   1.100 +~~~~~~~~~~~~~~
   1.101 +
   1.102 +XendDomainInfo now supports UUIDs being assigned to devices and the
   1.103 +domain itself. It will preserve the UUID for managed domains.
   1.104 +
   1.105 +A number of new functions are now in XendDomainInfo to provide an
   1.106 +interface to devices.
   1.107 +
   1.108 +XendNode
   1.109 +~~~~~~~~
   1.110 +
   1.111 +Represents the Host class in the Xen API and also contains an
   1.112 +incomplete representation of the physical CPUs availabel for the host.
   1.113 +
   1.114 +XendAuthSessions
   1.115 +~~~~~~~~~~~~~~~~
   1.116 +
   1.117 +An abstract authenticator for the Xen API. Currently it is an empty
   1.118 +implementation with rudimentary support for users. The plan is the add
   1.119 +PAM based authentication.
   1.120 +
   1.121 +XendAPI
   1.122 +~~~~~~~
   1.123 +
   1.124 +The guts of the Xen API implementation. Implements all the supported
   1.125 +functionality of the Xen API by placing calls to the relevent objects
   1.126 +like XendDomain and XendDomanInfo.
   1.127 +
   1.128 +The initialisation of the XendAPI object will actually install a
   1.129 +number of validation decorators in order to ensure the input is
   1.130 +correct. It is using some features of introspection and
   1.131 +metaprogramming in Python to reduce the amount of replication in the
   1.132 +code.
   1.133 +
   1.134 +XMLRPCServer
   1.135 +~~~~~~~~~~~~
   1.136 +
   1.137 +The XMLRPC Server will support both the new Xen API and the old XM
   1.138 +XMLRPC API. The support is clearly marked in the code.
   1.139 +