ia64/xen-unstable

changeset 14049:ee3ea729f5de

Added host.supported_bootloaders field.

Signed-off-by: Ewan Mellor <ewan@xensource.com>
author Ewan Mellor <ewan@xensource.com>
date Tue Feb 20 22:54:30 2007 +0000 (2007-02-20)
parents e0e300fda3f0
children df08fe145d24
files docs/xen-api/xenapi-datamodel.tex tools/python/xen/xend/XendAPI.py
line diff
     1.1 --- a/docs/xen-api/xenapi-datamodel.tex	Tue Feb 20 22:46:21 2007 +0000
     1.2 +++ b/docs/xen-api/xenapi-datamodel.tex	Tue Feb 20 22:54:30 2007 +0000
     1.3 @@ -4424,6 +4424,7 @@ Quals & Field & Type & Description \\
     1.4  $\mathit{RW}$ &  {\tt name/description} & string & a notes field containg human-readable description \\
     1.5  $\mathit{RO}_\mathit{run}$ &  {\tt software\_version} & (string $\rightarrow$ string) Map & version strings \\
     1.6  $\mathit{RW}$ &  {\tt other\_config} & (string $\rightarrow$ string) Map & additional configuration \\
     1.7 +$\mathit{RO}_\mathit{run}$ &  {\tt supported\_bootloaders} & string Set & a list of the bootloaders installed on the machine \\
     1.8  $\mathit{RO}_\mathit{run}$ &  {\tt resident\_VMs} & (VM ref) Set & list of VMs currently resident on host \\
     1.9  $\mathit{RW}$ &  {\tt logging} & (string $\rightarrow$ string) Map & logging configuration \\
    1.10  $\mathit{RO}_\mathit{run}$ &  {\tt PIFs} & (PIF ref) Set & physical network interfaces \\
    1.11 @@ -4952,6 +4953,38 @@ void
    1.12  \vspace{0.3cm}
    1.13  \vspace{0.3cm}
    1.14  \vspace{0.3cm}
    1.15 +\subsubsection{RPC name:~get\_supported\_bootloaders}
    1.16 +
    1.17 +{\bf Overview:} 
    1.18 +Get the supported\_bootloaders field of the given host.
    1.19 +
    1.20 + \noindent {\bf Signature:} 
    1.21 +\begin{verbatim} (string Set) get_supported_bootloaders (session_id s, host ref self)\end{verbatim}
    1.22 +
    1.23 +
    1.24 +\noindent{\bf Arguments:}
    1.25 +
    1.26 + 
    1.27 +\vspace{0.3cm}
    1.28 +\begin{tabular}{|c|c|p{7cm}|}
    1.29 + \hline
    1.30 +{\bf type} & {\bf name} & {\bf description} \\ \hline
    1.31 +{\tt host ref } & self & reference to the object \\ \hline 
    1.32 +
    1.33 +\end{tabular}
    1.34 +
    1.35 +\vspace{0.3cm}
    1.36 +
    1.37 + \noindent {\bf Return Type:} 
    1.38 +{\tt 
    1.39 +string Set
    1.40 +}
    1.41 +
    1.42 +
    1.43 +value of the field
    1.44 +\vspace{0.3cm}
    1.45 +\vspace{0.3cm}
    1.46 +\vspace{0.3cm}
    1.47  \subsubsection{RPC name:~get\_resident\_VMs}
    1.48  
    1.49  {\bf Overview:} 
     2.1 --- a/tools/python/xen/xend/XendAPI.py	Tue Feb 20 22:46:21 2007 +0000
     2.2 +++ b/tools/python/xen/xend/XendAPI.py	Tue Feb 20 22:54:30 2007 +0000
     2.3 @@ -626,7 +626,8 @@ class XendAPI(object):
     2.4      host_attr_ro = ['software_version',
     2.5                      'resident_VMs',
     2.6                      'host_CPUs',
     2.7 -                    'metrics']
     2.8 +                    'metrics',
     2.9 +                    'supported_bootloaders']
    2.10      
    2.11      host_attr_rw = ['name_label',
    2.12                      'name_description',
    2.13 @@ -678,6 +679,8 @@ class XendAPI(object):
    2.14          return xen_api_success(XendNode.instance().get_host_cpu_refs())
    2.15      def host_get_metrics(self, _, ref):
    2.16          return xen_api_success(XendNode.instance().host_metrics_uuid)
    2.17 +    def host_get_supported_bootloaders(self, session, host_ref):
    2.18 +        return xen_api_success(['pygrub'])
    2.19  
    2.20      # object methods
    2.21      def host_disable(self, session, host_ref):
    2.22 @@ -707,7 +710,8 @@ class XendAPI(object):
    2.23                    'software_version': node.xen_version(),
    2.24                    'resident_VMs': dom.get_domain_refs(),
    2.25                    'host_CPUs': node.get_host_cpu_refs(),
    2.26 -                  'metrics': node.host_metrics_uuid}
    2.27 +                  'metrics': node.host_metrics_uuid,
    2.28 +                  'supported_bootloaders': 'pygrub'}
    2.29          return xen_api_success(record)
    2.30  
    2.31      # class methods