direct-io.hg

changeset 14140:42dd9055ee1f

Implementation of host_metrics.get_all, PIF_metrics.get_all, and docs and
bindings for many of the get_all methods elsewhere that Xend already
implemented.

Signed-off-by: Ewan Mellor <ewan@xensource.com>
author Ewan Mellor <ewan@xensource.com>
date Tue Feb 27 01:05:32 2007 +0000 (2007-02-27)
parents 50e0616fd012
children c2e7bacf0919
files docs/xen-api/xenapi-datamodel.tex tools/libxen/include/xen_console.h tools/libxen/include/xen_host_cpu.h tools/libxen/include/xen_host_metrics.h tools/libxen/include/xen_pbd.h tools/libxen/include/xen_pif.h tools/libxen/include/xen_pif_metrics.h tools/libxen/include/xen_vbd.h tools/libxen/include/xen_vbd_metrics.h tools/libxen/include/xen_vdi.h tools/libxen/include/xen_vif.h tools/libxen/include/xen_vif_metrics.h tools/libxen/include/xen_vm_guest_metrics.h tools/libxen/include/xen_vm_metrics.h tools/libxen/src/xen_console.c tools/libxen/src/xen_host_cpu.c tools/libxen/src/xen_host_metrics.c tools/libxen/src/xen_pbd.c tools/libxen/src/xen_pif.c tools/libxen/src/xen_pif_metrics.c tools/libxen/src/xen_vbd.c tools/libxen/src/xen_vbd_metrics.c tools/libxen/src/xen_vdi.c tools/libxen/src/xen_vif.c tools/libxen/src/xen_vif_metrics.c tools/libxen/src/xen_vm_guest_metrics.c tools/libxen/src/xen_vm_metrics.c tools/python/xen/xend/XendAPI.py
line diff
     1.1 --- a/docs/xen-api/xenapi-datamodel.tex	Tue Feb 27 00:37:27 2007 +0000
     1.2 +++ b/docs/xen-api/xenapi-datamodel.tex	Tue Feb 27 01:05:32 2007 +0000
     1.3 @@ -4248,6 +4248,27 @@ Quals & Field & Type & Description \\
     1.4  \hline
     1.5  \end{longtable}
     1.6  \subsection{Additional RPCs associated with class: VM\_metrics}
     1.7 +\subsubsection{RPC name:~get\_all}
     1.8 +
     1.9 +{\bf Overview:} 
    1.10 +Return a list of all the VM\_metrics instances known to the system.
    1.11 +
    1.12 + \noindent {\bf Signature:} 
    1.13 +\begin{verbatim} ((VM_metrics ref) Set) get_all (session_id s)\end{verbatim}
    1.14 +
    1.15 +
    1.16 +\vspace{0.3cm}
    1.17 +
    1.18 + \noindent {\bf Return Type:} 
    1.19 +{\tt 
    1.20 +(VM\_metrics ref) Set
    1.21 +}
    1.22 +
    1.23 +
    1.24 +references to all objects
    1.25 +\vspace{0.3cm}
    1.26 +\vspace{0.3cm}
    1.27 +\vspace{0.3cm}
    1.28  \subsubsection{RPC name:~get\_uuid}
    1.29  
    1.30  {\bf Overview:} 
    1.31 @@ -4464,6 +4485,27 @@ Quals & Field & Type & Description \\
    1.32  \hline
    1.33  \end{longtable}
    1.34  \subsection{Additional RPCs associated with class: VM\_guest\_metrics}
    1.35 +\subsubsection{RPC name:~get\_all}
    1.36 +
    1.37 +{\bf Overview:} 
    1.38 +Return a list of all the VM\_guest\_metrics instances known to the system.
    1.39 +
    1.40 + \noindent {\bf Signature:} 
    1.41 +\begin{verbatim} ((VM_guest_metrics ref) Set) get_all (session_id s)\end{verbatim}
    1.42 +
    1.43 +
    1.44 +\vspace{0.3cm}
    1.45 +
    1.46 + \noindent {\bf Return Type:} 
    1.47 +{\tt 
    1.48 +(VM\_guest\_metrics ref) Set
    1.49 +}
    1.50 +
    1.51 +
    1.52 +references to all objects
    1.53 +\vspace{0.3cm}
    1.54 +\vspace{0.3cm}
    1.55 +\vspace{0.3cm}
    1.56  \subsubsection{RPC name:~get\_uuid}
    1.57  
    1.58  {\bf Overview:} 
    1.59 @@ -6073,6 +6115,27 @@ Quals & Field & Type & Description \\
    1.60  \hline
    1.61  \end{longtable}
    1.62  \subsection{Additional RPCs associated with class: host\_metrics}
    1.63 +\subsubsection{RPC name:~get\_all}
    1.64 +
    1.65 +{\bf Overview:} 
    1.66 +Return a list of all the host\_metrics instances known to the system.
    1.67 +
    1.68 + \noindent {\bf Signature:} 
    1.69 +\begin{verbatim} ((host_metrics ref) Set) get_all (session_id s)\end{verbatim}
    1.70 +
    1.71 +
    1.72 +\vspace{0.3cm}
    1.73 +
    1.74 + \noindent {\bf Return Type:} 
    1.75 +{\tt 
    1.76 +(host\_metrics ref) Set
    1.77 +}
    1.78 +
    1.79 +
    1.80 +references to all objects
    1.81 +\vspace{0.3cm}
    1.82 +\vspace{0.3cm}
    1.83 +\vspace{0.3cm}
    1.84  \subsubsection{RPC name:~get\_uuid}
    1.85  
    1.86  {\bf Overview:} 
    1.87 @@ -6289,6 +6352,27 @@ Quals & Field & Type & Description \\
    1.88  \hline
    1.89  \end{longtable}
    1.90  \subsection{Additional RPCs associated with class: host\_cpu}
    1.91 +\subsubsection{RPC name:~get\_all}
    1.92 +
    1.93 +{\bf Overview:} 
    1.94 +Return a list of all the host\_cpus known to the system.
    1.95 +
    1.96 + \noindent {\bf Signature:} 
    1.97 +\begin{verbatim} ((host_cpu ref) Set) get_all (session_id s)\end{verbatim}
    1.98 +
    1.99 +
   1.100 +\vspace{0.3cm}
   1.101 +
   1.102 + \noindent {\bf Return Type:} 
   1.103 +{\tt 
   1.104 +(host\_cpu ref) Set
   1.105 +}
   1.106 +
   1.107 +
   1.108 +references to all objects
   1.109 +\vspace{0.3cm}
   1.110 +\vspace{0.3cm}
   1.111 +\vspace{0.3cm}
   1.112  \subsubsection{RPC name:~get\_uuid}
   1.113  
   1.114  {\bf Overview:} 
   1.115 @@ -7100,6 +7184,27 @@ Quals & Field & Type & Description \\
   1.116  \hline
   1.117  \end{longtable}
   1.118  \subsection{Additional RPCs associated with class: VIF}
   1.119 +\subsubsection{RPC name:~get\_all}
   1.120 +
   1.121 +{\bf Overview:} 
   1.122 +Return a list of all the VIFs known to the system.
   1.123 +
   1.124 + \noindent {\bf Signature:} 
   1.125 +\begin{verbatim} ((VIF ref) Set) get_all (session_id s)\end{verbatim}
   1.126 +
   1.127 +
   1.128 +\vspace{0.3cm}
   1.129 +
   1.130 + \noindent {\bf Return Type:} 
   1.131 +{\tt 
   1.132 +(VIF ref) Set
   1.133 +}
   1.134 +
   1.135 +
   1.136 +references to all objects
   1.137 +\vspace{0.3cm}
   1.138 +\vspace{0.3cm}
   1.139 +\vspace{0.3cm}
   1.140  \subsubsection{RPC name:~get\_uuid}
   1.141  
   1.142  {\bf Overview:} 
   1.143 @@ -7906,6 +8011,27 @@ Quals & Field & Type & Description \\
   1.144  \hline
   1.145  \end{longtable}
   1.146  \subsection{Additional RPCs associated with class: VIF\_metrics}
   1.147 +\subsubsection{RPC name:~get\_all}
   1.148 +
   1.149 +{\bf Overview:} 
   1.150 +Return a list of all the VIF\_metrics instances known to the system.
   1.151 +
   1.152 + \noindent {\bf Signature:} 
   1.153 +\begin{verbatim} ((VIF_metrics ref) Set) get_all (session_id s)\end{verbatim}
   1.154 +
   1.155 +
   1.156 +\vspace{0.3cm}
   1.157 +
   1.158 + \noindent {\bf Return Type:} 
   1.159 +{\tt 
   1.160 +(VIF\_metrics ref) Set
   1.161 +}
   1.162 +
   1.163 +
   1.164 +references to all objects
   1.165 +\vspace{0.3cm}
   1.166 +\vspace{0.3cm}
   1.167 +\vspace{0.3cm}
   1.168  \subsubsection{RPC name:~get\_uuid}
   1.169  
   1.170  {\bf Overview:} 
   1.171 @@ -8166,6 +8292,27 @@ void
   1.172  \noindent{\bf Possible Error Codes:} {\tt PIF\_IS\_PHYSICAL}
   1.173  
   1.174  \vspace{0.6cm}
   1.175 +\subsubsection{RPC name:~get\_all}
   1.176 +
   1.177 +{\bf Overview:} 
   1.178 +Return a list of all the PIFs known to the system.
   1.179 +
   1.180 + \noindent {\bf Signature:} 
   1.181 +\begin{verbatim} ((PIF ref) Set) get_all (session_id s)\end{verbatim}
   1.182 +
   1.183 +
   1.184 +\vspace{0.3cm}
   1.185 +
   1.186 + \noindent {\bf Return Type:} 
   1.187 +{\tt 
   1.188 +(PIF ref) Set
   1.189 +}
   1.190 +
   1.191 +
   1.192 +references to all objects
   1.193 +\vspace{0.3cm}
   1.194 +\vspace{0.3cm}
   1.195 +\vspace{0.3cm}
   1.196  \subsubsection{RPC name:~get\_uuid}
   1.197  
   1.198  {\bf Overview:} 
   1.199 @@ -8642,6 +8789,27 @@ Quals & Field & Type & Description \\
   1.200  \hline
   1.201  \end{longtable}
   1.202  \subsection{Additional RPCs associated with class: PIF\_metrics}
   1.203 +\subsubsection{RPC name:~get\_all}
   1.204 +
   1.205 +{\bf Overview:} 
   1.206 +Return a list of all the PIF\_metrics instances known to the system.
   1.207 +
   1.208 + \noindent {\bf Signature:} 
   1.209 +\begin{verbatim} ((PIF_metrics ref) Set) get_all (session_id s)\end{verbatim}
   1.210 +
   1.211 +
   1.212 +\vspace{0.3cm}
   1.213 +
   1.214 + \noindent {\bf Return Type:} 
   1.215 +{\tt 
   1.216 +(PIF\_metrics ref) Set
   1.217 +}
   1.218 +
   1.219 +
   1.220 +references to all objects
   1.221 +\vspace{0.3cm}
   1.222 +\vspace{0.3cm}
   1.223 +\vspace{0.3cm}
   1.224  \subsubsection{RPC name:~get\_uuid}
   1.225  
   1.226  {\bf Overview:} 
   1.227 @@ -9561,6 +9729,27 @@ void
   1.228  \vspace{0.3cm}
   1.229  \vspace{0.3cm}
   1.230  \vspace{0.3cm}
   1.231 +\subsubsection{RPC name:~get\_all}
   1.232 +
   1.233 +{\bf Overview:} 
   1.234 +Return a list of all the VDIs known to the system.
   1.235 +
   1.236 + \noindent {\bf Signature:} 
   1.237 +\begin{verbatim} ((VDI ref) Set) get_all (session_id s)\end{verbatim}
   1.238 +
   1.239 +
   1.240 +\vspace{0.3cm}
   1.241 +
   1.242 + \noindent {\bf Return Type:} 
   1.243 +{\tt 
   1.244 +(VDI ref) Set
   1.245 +}
   1.246 +
   1.247 +
   1.248 +references to all objects
   1.249 +\vspace{0.3cm}
   1.250 +\vspace{0.3cm}
   1.251 +\vspace{0.3cm}
   1.252  \subsubsection{RPC name:~get\_uuid}
   1.253  
   1.254  {\bf Overview:} 
   1.255 @@ -10374,6 +10563,27 @@ void
   1.256  \vspace{0.3cm}
   1.257  \vspace{0.3cm}
   1.258  \vspace{0.3cm}
   1.259 +\subsubsection{RPC name:~get\_all}
   1.260 +
   1.261 +{\bf Overview:} 
   1.262 +Return a list of all the VBDs known to the system.
   1.263 +
   1.264 + \noindent {\bf Signature:} 
   1.265 +\begin{verbatim} ((VBD ref) Set) get_all (session_id s)\end{verbatim}
   1.266 +
   1.267 +
   1.268 +\vspace{0.3cm}
   1.269 +
   1.270 + \noindent {\bf Return Type:} 
   1.271 +{\tt 
   1.272 +(VBD ref) Set
   1.273 +}
   1.274 +
   1.275 +
   1.276 +references to all objects
   1.277 +\vspace{0.3cm}
   1.278 +\vspace{0.3cm}
   1.279 +\vspace{0.3cm}
   1.280  \subsubsection{RPC name:~get\_uuid}
   1.281  
   1.282  {\bf Overview:} 
   1.283 @@ -11246,6 +11456,27 @@ Quals & Field & Type & Description \\
   1.284  \hline
   1.285  \end{longtable}
   1.286  \subsection{Additional RPCs associated with class: VBD\_metrics}
   1.287 +\subsubsection{RPC name:~get\_all}
   1.288 +
   1.289 +{\bf Overview:} 
   1.290 +Return a list of all the VBD\_metrics instances known to the system.
   1.291 +
   1.292 + \noindent {\bf Signature:} 
   1.293 +\begin{verbatim} ((VBD_metrics ref) Set) get_all (session_id s)\end{verbatim}
   1.294 +
   1.295 +
   1.296 +\vspace{0.3cm}
   1.297 +
   1.298 + \noindent {\bf Return Type:} 
   1.299 +{\tt 
   1.300 +(VBD\_metrics ref) Set
   1.301 +}
   1.302 +
   1.303 +
   1.304 +references to all objects
   1.305 +\vspace{0.3cm}
   1.306 +\vspace{0.3cm}
   1.307 +\vspace{0.3cm}
   1.308  \subsubsection{RPC name:~get\_uuid}
   1.309  
   1.310  {\bf Overview:} 
   1.311 @@ -11427,6 +11658,27 @@ Quals & Field & Type & Description \\
   1.312  \hline
   1.313  \end{longtable}
   1.314  \subsection{Additional RPCs associated with class: PBD}
   1.315 +\subsubsection{RPC name:~get\_all}
   1.316 +
   1.317 +{\bf Overview:} 
   1.318 +Return a list of all the PBDs known to the system.
   1.319 +
   1.320 + \noindent {\bf Signature:} 
   1.321 +\begin{verbatim} ((PBD ref) Set) get_all (session_id s)\end{verbatim}
   1.322 +
   1.323 +
   1.324 +\vspace{0.3cm}
   1.325 +
   1.326 + \noindent {\bf Return Type:} 
   1.327 +{\tt 
   1.328 +(PBD ref) Set
   1.329 +}
   1.330 +
   1.331 +
   1.332 +references to all objects
   1.333 +\vspace{0.3cm}
   1.334 +\vspace{0.3cm}
   1.335 +\vspace{0.3cm}
   1.336  \subsubsection{RPC name:~get\_uuid}
   1.337  
   1.338  {\bf Overview:} 
   1.339 @@ -12243,6 +12495,27 @@ Quals & Field & Type & Description \\
   1.340  \hline
   1.341  \end{longtable}
   1.342  \subsection{Additional RPCs associated with class: console}
   1.343 +\subsubsection{RPC name:~get\_all}
   1.344 +
   1.345 +{\bf Overview:} 
   1.346 +Return a list of all the consoles known to the system.
   1.347 +
   1.348 + \noindent {\bf Signature:} 
   1.349 +\begin{verbatim} ((console ref) Set) get_all (session_id s)\end{verbatim}
   1.350 +
   1.351 +
   1.352 +\vspace{0.3cm}
   1.353 +
   1.354 + \noindent {\bf Return Type:} 
   1.355 +{\tt 
   1.356 +(console ref) Set
   1.357 +}
   1.358 +
   1.359 +
   1.360 +references to all objects
   1.361 +\vspace{0.3cm}
   1.362 +\vspace{0.3cm}
   1.363 +\vspace{0.3cm}
   1.364  \subsubsection{RPC name:~get\_uuid}
   1.365  
   1.366  {\bf Overview:} 
     2.1 --- a/tools/libxen/include/xen_console.h	Tue Feb 27 00:37:27 2007 +0000
     2.2 +++ b/tools/libxen/include/xen_console.h	Tue Feb 27 01:05:32 2007 +0000
     2.3 @@ -237,4 +237,11 @@ extern bool
     2.4  xen_console_remove_from_other_config(xen_session *session, xen_console console, char *key);
     2.5  
     2.6  
     2.7 +/**
     2.8 + * Return a list of all the consoles known to the system.
     2.9 + */
    2.10 +extern bool
    2.11 +xen_console_get_all(xen_session *session, struct xen_console_set **result);
    2.12 +
    2.13 +
    2.14  #endif
     3.1 --- a/tools/libxen/include/xen_host_cpu.h	Tue Feb 27 00:37:27 2007 +0000
     3.2 +++ b/tools/libxen/include/xen_host_cpu.h	Tue Feb 27 01:05:32 2007 +0000
     3.3 @@ -229,4 +229,11 @@ extern bool
     3.4  xen_host_cpu_get_utilisation(xen_session *session, double *result, xen_host_cpu host_cpu);
     3.5  
     3.6  
     3.7 +/**
     3.8 + * Return a list of all the host_cpus known to the system.
     3.9 + */
    3.10 +extern bool
    3.11 +xen_host_cpu_get_all(xen_session *session, struct xen_host_cpu_set **result);
    3.12 +
    3.13 +
    3.14  #endif
     4.1 --- a/tools/libxen/include/xen_host_metrics.h	Tue Feb 27 00:37:27 2007 +0000
     4.2 +++ b/tools/libxen/include/xen_host_metrics.h	Tue Feb 27 01:05:32 2007 +0000
     4.3 @@ -1,5 +1,5 @@
     4.4  /*
     4.5 - * Copyright (c) 2006, XenSource Inc.
     4.6 + * Copyright (c) 2006-2007, XenSource Inc.
     4.7   *
     4.8   * This library is free software; you can redistribute it and/or
     4.9   * modify it under the terms of the GNU Lesser General Public
    4.10 @@ -190,4 +190,11 @@ extern bool
    4.11  xen_host_metrics_get_memory_free(xen_session *session, int64_t *result, xen_host_metrics host_metrics);
    4.12  
    4.13  
    4.14 +/**
    4.15 + * Return a list of all the host_metrics instances known to the system.
    4.16 + */
    4.17 +extern bool
    4.18 +xen_host_metrics_get_all(xen_session *session, struct xen_host_metrics_set **result);
    4.19 +
    4.20 +
    4.21  #endif
     5.1 --- a/tools/libxen/include/xen_pbd.h	Tue Feb 27 00:37:27 2007 +0000
     5.2 +++ b/tools/libxen/include/xen_pbd.h	Tue Feb 27 01:05:32 2007 +0000
     5.3 @@ -1,5 +1,5 @@
     5.4  /*
     5.5 - * Copyright (c) 2006, XenSource Inc.
     5.6 + * Copyright (c) 2006-2007, XenSource Inc.
     5.7   *
     5.8   * This library is free software; you can redistribute it and/or
     5.9   * modify it under the terms of the GNU Lesser General Public
    5.10 @@ -213,4 +213,11 @@ extern bool
    5.11  xen_pbd_get_currently_attached(xen_session *session, bool *result, xen_pbd pbd);
    5.12  
    5.13  
    5.14 +/**
    5.15 + * Return a list of all the PBDs known to the system.
    5.16 + */
    5.17 +extern bool
    5.18 +xen_pbd_get_all(xen_session *session, struct xen_pbd_set **result);
    5.19 +
    5.20 +
    5.21  #endif
     6.1 --- a/tools/libxen/include/xen_pif.h	Tue Feb 27 00:37:27 2007 +0000
     6.2 +++ b/tools/libxen/include/xen_pif.h	Tue Feb 27 01:05:32 2007 +0000
     6.3 @@ -1,5 +1,5 @@
     6.4  /*
     6.5 - * Copyright (c) 2006, XenSource Inc.
     6.6 + * Copyright (c) 2006-2007, XenSource Inc.
     6.7   *
     6.8   * This library is free software; you can redistribute it and/or
     6.9   * modify it under the terms of the GNU Lesser General Public
    6.10 @@ -267,4 +267,11 @@ extern bool
    6.11  xen_pif_destroy(xen_session *session, xen_pif self);
    6.12  
    6.13  
    6.14 +/**
    6.15 + * Return a list of all the PIFs known to the system.
    6.16 + */
    6.17 +extern bool
    6.18 +xen_pif_get_all(xen_session *session, struct xen_pif_set **result);
    6.19 +
    6.20 +
    6.21  #endif
     7.1 --- a/tools/libxen/include/xen_pif_metrics.h	Tue Feb 27 00:37:27 2007 +0000
     7.2 +++ b/tools/libxen/include/xen_pif_metrics.h	Tue Feb 27 01:05:32 2007 +0000
     7.3 @@ -1,5 +1,5 @@
     7.4  /*
     7.5 - * Copyright (c) 2006, XenSource Inc.
     7.6 + * Copyright (c) 2006-2007, XenSource Inc.
     7.7   *
     7.8   * This library is free software; you can redistribute it and/or
     7.9   * modify it under the terms of the GNU Lesser General Public
    7.10 @@ -189,4 +189,11 @@ extern bool
    7.11  xen_pif_metrics_get_io_write_kbs(xen_session *session, double *result, xen_pif_metrics pif_metrics);
    7.12  
    7.13  
    7.14 +/**
    7.15 + * Return a list of all the PIF_metrics instances known to the system.
    7.16 + */
    7.17 +extern bool
    7.18 +xen_pif_metrics_get_all(xen_session *session, struct xen_pif_metrics_set **result);
    7.19 +
    7.20 +
    7.21  #endif
     8.1 --- a/tools/libxen/include/xen_vbd.h	Tue Feb 27 00:37:27 2007 +0000
     8.2 +++ b/tools/libxen/include/xen_vbd.h	Tue Feb 27 01:05:32 2007 +0000
     8.3 @@ -357,4 +357,11 @@ extern bool
     8.4  xen_vbd_media_change(xen_session *session, xen_vbd vbd, xen_vdi vdi);
     8.5  
     8.6  
     8.7 +/**
     8.8 + * Return a list of all the VBDs known to the system.
     8.9 + */
    8.10 +extern bool
    8.11 +xen_vbd_get_all(xen_session *session, struct xen_vbd_set **result);
    8.12 +
    8.13 +
    8.14  #endif
     9.1 --- a/tools/libxen/include/xen_vbd_metrics.h	Tue Feb 27 00:37:27 2007 +0000
     9.2 +++ b/tools/libxen/include/xen_vbd_metrics.h	Tue Feb 27 01:05:32 2007 +0000
     9.3 @@ -180,4 +180,11 @@ extern bool
     9.4  xen_vbd_metrics_get_io_write_kbs(xen_session *session, double *result, xen_vbd_metrics vbd_metrics);
     9.5  
     9.6  
     9.7 +/**
     9.8 + * Return a list of all the VBD_metrics instances known to the system.
     9.9 + */
    9.10 +extern bool
    9.11 +xen_vbd_metrics_get_all(xen_session *session, struct xen_vbd_metrics_set **result);
    9.12 +
    9.13 +
    9.14  #endif
    10.1 --- a/tools/libxen/include/xen_vdi.h	Tue Feb 27 00:37:27 2007 +0000
    10.2 +++ b/tools/libxen/include/xen_vdi.h	Tue Feb 27 01:05:32 2007 +0000
    10.3 @@ -335,4 +335,11 @@ extern bool
    10.4  xen_vdi_resize(xen_session *session, xen_vdi vdi, int64_t size);
    10.5  
    10.6  
    10.7 +/**
    10.8 + * Return a list of all the VDIs known to the system.
    10.9 + */
   10.10 +extern bool
   10.11 +xen_vdi_get_all(xen_session *session, struct xen_vdi_set **result);
   10.12 +
   10.13 +
   10.14  #endif
    11.1 --- a/tools/libxen/include/xen_vif.h	Tue Feb 27 00:37:27 2007 +0000
    11.2 +++ b/tools/libxen/include/xen_vif.h	Tue Feb 27 01:05:32 2007 +0000
    11.3 @@ -331,4 +331,11 @@ extern bool
    11.4  xen_vif_remove_from_qos_algorithm_params(xen_session *session, xen_vif vif, char *key);
    11.5  
    11.6  
    11.7 +/**
    11.8 + * Return a list of all the VIFs known to the system.
    11.9 + */
   11.10 +extern bool
   11.11 +xen_vif_get_all(xen_session *session, struct xen_vif_set **result);
   11.12 +
   11.13 +
   11.14  #endif
    12.1 --- a/tools/libxen/include/xen_vif_metrics.h	Tue Feb 27 00:37:27 2007 +0000
    12.2 +++ b/tools/libxen/include/xen_vif_metrics.h	Tue Feb 27 01:05:32 2007 +0000
    12.3 @@ -180,4 +180,11 @@ extern bool
    12.4  xen_vif_metrics_get_io_write_kbs(xen_session *session, double *result, xen_vif_metrics vif_metrics);
    12.5  
    12.6  
    12.7 +/**
    12.8 + * Return a list of all the VIF_metrics instances known to the system.
    12.9 + */
   12.10 +extern bool
   12.11 +xen_vif_metrics_get_all(xen_session *session, struct xen_vif_metrics_set **result);
   12.12 +
   12.13 +
   12.14  #endif
    13.1 --- a/tools/libxen/include/xen_vm_guest_metrics.h	Tue Feb 27 00:37:27 2007 +0000
    13.2 +++ b/tools/libxen/include/xen_vm_guest_metrics.h	Tue Feb 27 01:05:32 2007 +0000
    13.3 @@ -224,4 +224,11 @@ extern bool
    13.4  xen_vm_guest_metrics_get_other(xen_session *session, xen_string_string_map **result, xen_vm_guest_metrics vm_guest_metrics);
    13.5  
    13.6  
    13.7 +/**
    13.8 + * Return a list of all the VM_guest_metrics instances known to the system.
    13.9 + */
   13.10 +extern bool
   13.11 +xen_vm_guest_metrics_get_all(xen_session *session, struct xen_vm_guest_metrics_set **result);
   13.12 +
   13.13 +
   13.14  #endif
    14.1 --- a/tools/libxen/include/xen_vm_metrics.h	Tue Feb 27 00:37:27 2007 +0000
    14.2 +++ b/tools/libxen/include/xen_vm_metrics.h	Tue Feb 27 01:05:32 2007 +0000
    14.3 @@ -189,4 +189,11 @@ extern bool
    14.4  xen_vm_metrics_get_vcpus_utilisation(xen_session *session, xen_int_float_map **result, xen_vm_metrics vm_metrics);
    14.5  
    14.6  
    14.7 +/**
    14.8 + * Return a list of all the VM_metrics instances known to the system.
    14.9 + */
   14.10 +extern bool
   14.11 +xen_vm_metrics_get_all(xen_session *session, struct xen_vm_metrics_set **result);
   14.12 +
   14.13 +
   14.14  #endif
    15.1 --- a/tools/libxen/src/xen_console.c	Tue Feb 27 00:37:27 2007 +0000
    15.2 +++ b/tools/libxen/src/xen_console.c	Tue Feb 27 01:05:32 2007 +0000
    15.3 @@ -270,6 +270,18 @@ xen_console_remove_from_other_config(xen
    15.4  
    15.5  
    15.6  bool
    15.7 +xen_console_get_all(xen_session *session, struct xen_console_set **result)
    15.8 +{
    15.9 +
   15.10 +    abstract_type result_type = abstract_type_string_set;
   15.11 +
   15.12 +    *result = NULL;
   15.13 +    xen_call_(session, "console.get_all", NULL, 0, &result_type, result);
   15.14 +    return session->ok;
   15.15 +}
   15.16 +
   15.17 +
   15.18 +bool
   15.19  xen_console_get_uuid(xen_session *session, char **result, xen_console console)
   15.20  {
   15.21      *result = session->ok ? xen_strdup_((char *)console) : NULL;
    16.1 --- a/tools/libxen/src/xen_host_cpu.c	Tue Feb 27 00:37:27 2007 +0000
    16.2 +++ b/tools/libxen/src/xen_host_cpu.c	Tue Feb 27 01:05:32 2007 +0000
    16.3 @@ -268,6 +268,18 @@ xen_host_cpu_get_utilisation(xen_session
    16.4  
    16.5  
    16.6  bool
    16.7 +xen_host_cpu_get_all(xen_session *session, struct xen_host_cpu_set **result)
    16.8 +{
    16.9 +
   16.10 +    abstract_type result_type = abstract_type_string_set;
   16.11 +
   16.12 +    *result = NULL;
   16.13 +    xen_call_(session, "host_cpu.get_all", NULL, 0, &result_type, result);
   16.14 +    return session->ok;
   16.15 +}
   16.16 +
   16.17 +
   16.18 +bool
   16.19  xen_host_cpu_get_uuid(xen_session *session, char **result, xen_host_cpu host_cpu)
   16.20  {
   16.21      *result = session->ok ? xen_strdup_((char *)host_cpu) : NULL;
    17.1 --- a/tools/libxen/src/xen_host_metrics.c	Tue Feb 27 00:37:27 2007 +0000
    17.2 +++ b/tools/libxen/src/xen_host_metrics.c	Tue Feb 27 01:05:32 2007 +0000
    17.3 @@ -1,5 +1,5 @@
    17.4  /*
    17.5 - * Copyright (c) 2006, XenSource Inc.
    17.6 + * Copyright (c) 2006-2007, XenSource Inc.
    17.7   *
    17.8   * This library is free software; you can redistribute it and/or
    17.9   * modify it under the terms of the GNU Lesser General Public
   17.10 @@ -165,6 +165,18 @@ xen_host_metrics_get_memory_free(xen_ses
   17.11  
   17.12  
   17.13  bool
   17.14 +xen_host_metrics_get_all(xen_session *session, struct xen_host_metrics_set **result)
   17.15 +{
   17.16 +
   17.17 +    abstract_type result_type = abstract_type_string_set;
   17.18 +
   17.19 +    *result = NULL;
   17.20 +    xen_call_(session, "host_metrics.get_all", NULL, 0, &result_type, result);
   17.21 +    return session->ok;
   17.22 +}
   17.23 +
   17.24 +
   17.25 +bool
   17.26  xen_host_metrics_get_uuid(xen_session *session, char **result, xen_host_metrics host_metrics)
   17.27  {
   17.28      *result = session->ok ? xen_strdup_((char *)host_metrics) : NULL;
    18.1 --- a/tools/libxen/src/xen_pbd.c	Tue Feb 27 00:37:27 2007 +0000
    18.2 +++ b/tools/libxen/src/xen_pbd.c	Tue Feb 27 01:05:32 2007 +0000
    18.3 @@ -1,5 +1,5 @@
    18.4  /*
    18.5 - * Copyright (c) 2006, XenSource Inc.
    18.6 + * Copyright (c) 2006-2007, XenSource Inc.
    18.7   *
    18.8   * This library is free software; you can redistribute it and/or
    18.9   * modify it under the terms of the GNU Lesser General Public
   18.10 @@ -221,6 +221,18 @@ xen_pbd_get_currently_attached(xen_sessi
   18.11  
   18.12  
   18.13  bool
   18.14 +xen_pbd_get_all(xen_session *session, struct xen_pbd_set **result)
   18.15 +{
   18.16 +
   18.17 +    abstract_type result_type = abstract_type_string_set;
   18.18 +
   18.19 +    *result = NULL;
   18.20 +    xen_call_(session, "PBD.get_all", NULL, 0, &result_type, result);
   18.21 +    return session->ok;
   18.22 +}
   18.23 +
   18.24 +
   18.25 +bool
   18.26  xen_pbd_get_uuid(xen_session *session, char **result, xen_pbd pbd)
   18.27  {
   18.28      *result = session->ok ? xen_strdup_((char *)pbd) : NULL;
    19.1 --- a/tools/libxen/src/xen_pif.c	Tue Feb 27 00:37:27 2007 +0000
    19.2 +++ b/tools/libxen/src/xen_pif.c	Tue Feb 27 01:05:32 2007 +0000
    19.3 @@ -1,5 +1,5 @@
    19.4  /*
    19.5 - * Copyright (c) 2006, XenSource Inc.
    19.6 + * Copyright (c) 2006-2007, XenSource Inc.
    19.7   *
    19.8   * This library is free software; you can redistribute it and/or
    19.9   * modify it under the terms of the GNU Lesser General Public
   19.10 @@ -352,6 +352,18 @@ xen_pif_destroy(xen_session *session, xe
   19.11  
   19.12  
   19.13  bool
   19.14 +xen_pif_get_all(xen_session *session, struct xen_pif_set **result)
   19.15 +{
   19.16 +
   19.17 +    abstract_type result_type = abstract_type_string_set;
   19.18 +
   19.19 +    *result = NULL;
   19.20 +    xen_call_(session, "PIF.get_all", NULL, 0, &result_type, result);
   19.21 +    return session->ok;
   19.22 +}
   19.23 +
   19.24 +
   19.25 +bool
   19.26  xen_pif_get_uuid(xen_session *session, char **result, xen_pif pif)
   19.27  {
   19.28      *result = session->ok ? xen_strdup_((char *)pif) : NULL;
    20.1 --- a/tools/libxen/src/xen_pif_metrics.c	Tue Feb 27 00:37:27 2007 +0000
    20.2 +++ b/tools/libxen/src/xen_pif_metrics.c	Tue Feb 27 01:05:32 2007 +0000
    20.3 @@ -1,5 +1,5 @@
    20.4  /*
    20.5 - * Copyright (c) 2006, XenSource Inc.
    20.6 + * Copyright (c) 2006-2007, XenSource Inc.
    20.7   *
    20.8   * This library is free software; you can redistribute it and/or
    20.9   * modify it under the terms of the GNU Lesser General Public
   20.10 @@ -165,6 +165,18 @@ xen_pif_metrics_get_io_write_kbs(xen_ses
   20.11  
   20.12  
   20.13  bool
   20.14 +xen_pif_metrics_get_all(xen_session *session, struct xen_pif_metrics_set **result)
   20.15 +{
   20.16 +
   20.17 +    abstract_type result_type = abstract_type_string_set;
   20.18 +
   20.19 +    *result = NULL;
   20.20 +    xen_call_(session, "PIF_metrics.get_all", NULL, 0, &result_type, result);
   20.21 +    return session->ok;
   20.22 +}
   20.23 +
   20.24 +
   20.25 +bool
   20.26  xen_pif_metrics_get_uuid(xen_session *session, char **result, xen_pif_metrics pif_metrics)
   20.27  {
   20.28      *result = session->ok ? xen_strdup_((char *)pif_metrics) : NULL;
    21.1 --- a/tools/libxen/src/xen_vbd.c	Tue Feb 27 00:37:27 2007 +0000
    21.2 +++ b/tools/libxen/src/xen_vbd.c	Tue Feb 27 01:05:32 2007 +0000
    21.3 @@ -552,6 +552,18 @@ xen_vbd_media_change(xen_session *sessio
    21.4  
    21.5  
    21.6  bool
    21.7 +xen_vbd_get_all(xen_session *session, struct xen_vbd_set **result)
    21.8 +{
    21.9 +
   21.10 +    abstract_type result_type = abstract_type_string_set;
   21.11 +
   21.12 +    *result = NULL;
   21.13 +    xen_call_(session, "VBD.get_all", NULL, 0, &result_type, result);
   21.14 +    return session->ok;
   21.15 +}
   21.16 +
   21.17 +
   21.18 +bool
   21.19  xen_vbd_get_uuid(xen_session *session, char **result, xen_vbd vbd)
   21.20  {
   21.21      *result = session->ok ? xen_strdup_((char *)vbd) : NULL;
    22.1 --- a/tools/libxen/src/xen_vbd_metrics.c	Tue Feb 27 00:37:27 2007 +0000
    22.2 +++ b/tools/libxen/src/xen_vbd_metrics.c	Tue Feb 27 01:05:32 2007 +0000
    22.3 @@ -143,6 +143,18 @@ xen_vbd_metrics_get_io_write_kbs(xen_ses
    22.4  
    22.5  
    22.6  bool
    22.7 +xen_vbd_metrics_get_all(xen_session *session, struct xen_vbd_metrics_set **result)
    22.8 +{
    22.9 +
   22.10 +    abstract_type result_type = abstract_type_string_set;
   22.11 +
   22.12 +    *result = NULL;
   22.13 +    xen_call_(session, "VBD_metrics.get_all", NULL, 0, &result_type, result);
   22.14 +    return session->ok;
   22.15 +}
   22.16 +
   22.17 +
   22.18 +bool
   22.19  xen_vbd_metrics_get_uuid(xen_session *session, char **result, xen_vbd_metrics vbd_metrics)
   22.20  {
   22.21      *result = session->ok ? xen_strdup_((char *)vbd_metrics) : NULL;
    23.1 --- a/tools/libxen/src/xen_vdi.c	Tue Feb 27 00:37:27 2007 +0000
    23.2 +++ b/tools/libxen/src/xen_vdi.c	Tue Feb 27 01:05:32 2007 +0000
    23.3 @@ -507,6 +507,18 @@ xen_vdi_resize(xen_session *session, xen
    23.4  
    23.5  
    23.6  bool
    23.7 +xen_vdi_get_all(xen_session *session, struct xen_vdi_set **result)
    23.8 +{
    23.9 +
   23.10 +    abstract_type result_type = abstract_type_string_set;
   23.11 +
   23.12 +    *result = NULL;
   23.13 +    xen_call_(session, "VDI.get_all", NULL, 0, &result_type, result);
   23.14 +    return session->ok;
   23.15 +}
   23.16 +
   23.17 +
   23.18 +bool
   23.19  xen_vdi_get_uuid(xen_session *session, char **result, xen_vdi vdi)
   23.20  {
   23.21      *result = session->ok ? xen_strdup_((char *)vdi) : NULL;
    24.1 --- a/tools/libxen/src/xen_vif.c	Tue Feb 27 00:37:27 2007 +0000
    24.2 +++ b/tools/libxen/src/xen_vif.c	Tue Feb 27 01:05:32 2007 +0000
    24.3 @@ -500,6 +500,18 @@ xen_vif_remove_from_qos_algorithm_params
    24.4  
    24.5  
    24.6  bool
    24.7 +xen_vif_get_all(xen_session *session, struct xen_vif_set **result)
    24.8 +{
    24.9 +
   24.10 +    abstract_type result_type = abstract_type_string_set;
   24.11 +
   24.12 +    *result = NULL;
   24.13 +    xen_call_(session, "VIF.get_all", NULL, 0, &result_type, result);
   24.14 +    return session->ok;
   24.15 +}
   24.16 +
   24.17 +
   24.18 +bool
   24.19  xen_vif_get_uuid(xen_session *session, char **result, xen_vif vif)
   24.20  {
   24.21      *result = session->ok ? xen_strdup_((char *)vif) : NULL;
    25.1 --- a/tools/libxen/src/xen_vif_metrics.c	Tue Feb 27 00:37:27 2007 +0000
    25.2 +++ b/tools/libxen/src/xen_vif_metrics.c	Tue Feb 27 01:05:32 2007 +0000
    25.3 @@ -143,6 +143,18 @@ xen_vif_metrics_get_io_write_kbs(xen_ses
    25.4  
    25.5  
    25.6  bool
    25.7 +xen_vif_metrics_get_all(xen_session *session, struct xen_vif_metrics_set **result)
    25.8 +{
    25.9 +
   25.10 +    abstract_type result_type = abstract_type_string_set;
   25.11 +
   25.12 +    *result = NULL;
   25.13 +    xen_call_(session, "VIF_metrics.get_all", NULL, 0, &result_type, result);
   25.14 +    return session->ok;
   25.15 +}
   25.16 +
   25.17 +
   25.18 +bool
   25.19  xen_vif_metrics_get_uuid(xen_session *session, char **result, xen_vif_metrics vif_metrics)
   25.20  {
   25.21      *result = session->ok ? xen_strdup_((char *)vif_metrics) : NULL;
    26.1 --- a/tools/libxen/src/xen_vm_guest_metrics.c	Tue Feb 27 00:37:27 2007 +0000
    26.2 +++ b/tools/libxen/src/xen_vm_guest_metrics.c	Tue Feb 27 01:05:32 2007 +0000
    26.3 @@ -254,6 +254,18 @@ xen_vm_guest_metrics_get_other(xen_sessi
    26.4  
    26.5  
    26.6  bool
    26.7 +xen_vm_guest_metrics_get_all(xen_session *session, struct xen_vm_guest_metrics_set **result)
    26.8 +{
    26.9 +
   26.10 +    abstract_type result_type = abstract_type_string_set;
   26.11 +
   26.12 +    *result = NULL;
   26.13 +    xen_call_(session, "VM_guest_metrics.get_all", NULL, 0, &result_type, result);
   26.14 +    return session->ok;
   26.15 +}
   26.16 +
   26.17 +
   26.18 +bool
   26.19  xen_vm_guest_metrics_get_uuid(xen_session *session, char **result, xen_vm_guest_metrics vm_guest_metrics)
   26.20  {
   26.21      *result = session->ok ? xen_strdup_((char *)vm_guest_metrics) : NULL;
    27.1 --- a/tools/libxen/src/xen_vm_metrics.c	Tue Feb 27 00:37:27 2007 +0000
    27.2 +++ b/tools/libxen/src/xen_vm_metrics.c	Tue Feb 27 01:05:32 2007 +0000
    27.3 @@ -165,6 +165,18 @@ xen_vm_metrics_get_vcpus_utilisation(xen
    27.4  
    27.5  
    27.6  bool
    27.7 +xen_vm_metrics_get_all(xen_session *session, struct xen_vm_metrics_set **result)
    27.8 +{
    27.9 +
   27.10 +    abstract_type result_type = abstract_type_string_set;
   27.11 +
   27.12 +    *result = NULL;
   27.13 +    xen_call_(session, "VM_metrics.get_all", NULL, 0, &result_type, result);
   27.14 +    return session->ok;
   27.15 +}
   27.16 +
   27.17 +
   27.18 +bool
   27.19  xen_vm_metrics_get_uuid(xen_session *session, char **result, xen_vm_metrics vm_metrics)
   27.20  {
   27.21      *result = session->ok ? xen_strdup_((char *)vm_metrics) : NULL;
    28.1 --- a/tools/python/xen/xend/XendAPI.py	Tue Feb 27 00:37:27 2007 +0000
    28.2 +++ b/tools/python/xen/xend/XendAPI.py	Tue Feb 27 01:05:32 2007 +0000
    28.3 @@ -807,6 +807,9 @@ class XendAPI(object):
    28.4      host_metrics_attr_rw = []
    28.5      host_metrics_methods = []
    28.6  
    28.7 +    def host_metrics_get_all(self, _):
    28.8 +        return xen_api_success([XendNode.instance().host_metrics_uuid])
    28.9 +
   28.10      def _host_metrics_get(self, ref, f):
   28.11          return xen_api_success(getattr(node, f)())
   28.12  
   28.13 @@ -971,6 +974,9 @@ class XendAPI(object):
   28.14      PIF_metrics_attr_rw = []
   28.15      PIF_methods = []
   28.16  
   28.17 +    def PIF_metrics_get_all(self, _):
   28.18 +        return xen_api_success(XendNode.instance().pif_metrics.keys())
   28.19 +
   28.20      def _PIF_metrics_get(self, ref):
   28.21          return XendNode.instance().pif_metrics[ref]
   28.22