ia64/xen-unstable

changeset 14048:e0e300fda3f0

Remove host.create and host.destroy -- these never made any sense.

Signed-off-by: Ewan Mellor <ewan@xensource.com>
author Ewan Mellor <ewan@xensource.com>
date Tue Feb 20 22:46:21 2007 +0000 (2007-02-20)
parents bab07bed5c0a
children ee3ea729f5de
files docs/xen-api/xenapi-datamodel.tex tools/libxen/include/xen_host.h tools/libxen/src/xen_host.c tools/python/xen/xend/XendAPI.py
line diff
     1.1 --- a/docs/xen-api/xenapi-datamodel.tex	Tue Feb 20 22:40:55 2007 +0000
     1.2 +++ b/docs/xen-api/xenapi-datamodel.tex	Tue Feb 20 22:46:21 2007 +0000
     1.3 @@ -5381,70 +5381,6 @@ value of the field
     1.4  \vspace{0.3cm}
     1.5  \vspace{0.3cm}
     1.6  \vspace{0.3cm}
     1.7 -\subsubsection{RPC name:~create}
     1.8 -
     1.9 -{\bf Overview:} 
    1.10 -Create a new host instance, and return its handle.
    1.11 -
    1.12 - \noindent {\bf Signature:} 
    1.13 -\begin{verbatim} (host ref) create (session_id s, host record args)\end{verbatim}
    1.14 -
    1.15 -
    1.16 -\noindent{\bf Arguments:}
    1.17 -
    1.18 - 
    1.19 -\vspace{0.3cm}
    1.20 -\begin{tabular}{|c|c|p{7cm}|}
    1.21 - \hline
    1.22 -{\bf type} & {\bf name} & {\bf description} \\ \hline
    1.23 -{\tt host record } & args & All constructor arguments \\ \hline 
    1.24 -
    1.25 -\end{tabular}
    1.26 -
    1.27 -\vspace{0.3cm}
    1.28 -
    1.29 - \noindent {\bf Return Type:} 
    1.30 -{\tt 
    1.31 -host ref
    1.32 -}
    1.33 -
    1.34 -
    1.35 -reference to the newly created object
    1.36 -\vspace{0.3cm}
    1.37 -\vspace{0.3cm}
    1.38 -\vspace{0.3cm}
    1.39 -\subsubsection{RPC name:~destroy}
    1.40 -
    1.41 -{\bf Overview:} 
    1.42 -Destroy the specified host instance.
    1.43 -
    1.44 - \noindent {\bf Signature:} 
    1.45 -\begin{verbatim} void destroy (session_id s, host ref self)\end{verbatim}
    1.46 -
    1.47 -
    1.48 -\noindent{\bf Arguments:}
    1.49 -
    1.50 - 
    1.51 -\vspace{0.3cm}
    1.52 -\begin{tabular}{|c|c|p{7cm}|}
    1.53 - \hline
    1.54 -{\bf type} & {\bf name} & {\bf description} \\ \hline
    1.55 -{\tt host ref } & self & reference to the object \\ \hline 
    1.56 -
    1.57 -\end{tabular}
    1.58 -
    1.59 -\vspace{0.3cm}
    1.60 -
    1.61 - \noindent {\bf Return Type:} 
    1.62 -{\tt 
    1.63 -void
    1.64 -}
    1.65 -
    1.66 -
    1.67 -
    1.68 -\vspace{0.3cm}
    1.69 -\vspace{0.3cm}
    1.70 -\vspace{0.3cm}
    1.71  \subsubsection{RPC name:~get\_by\_uuid}
    1.72  
    1.73  {\bf Overview:} 
     2.1 --- a/tools/libxen/include/xen_host.h	Tue Feb 20 22:40:55 2007 +0000
     2.2 +++ b/tools/libxen/include/xen_host.h	Tue Feb 20 22:46:21 2007 +0000
     2.3 @@ -1,5 +1,5 @@
     2.4  /*
     2.5 - * Copyright (c) 2006, XenSource Inc.
     2.6 + * Copyright (c) 2006-2007, XenSource Inc.
     2.7   *
     2.8   * This library is free software; you can redistribute it and/or
     2.9   * modify it under the terms of the GNU Lesser General Public
    2.10 @@ -177,20 +177,6 @@ xen_host_get_by_uuid(xen_session *sessio
    2.11  
    2.12  
    2.13  /**
    2.14 - * Create a new host instance, and return its handle.
    2.15 - */
    2.16 -extern bool
    2.17 -xen_host_create(xen_session *session, xen_host *result, xen_host_record *record);
    2.18 -
    2.19 -
    2.20 -/**
    2.21 - * Destroy the specified host instance.
    2.22 - */
    2.23 -extern bool
    2.24 -xen_host_destroy(xen_session *session, xen_host host);
    2.25 -
    2.26 -
    2.27 -/**
    2.28   * Get all the host instances with the given label.
    2.29   */
    2.30  extern bool
     3.1 --- a/tools/libxen/src/xen_host.c	Tue Feb 20 22:40:55 2007 +0000
     3.2 +++ b/tools/libxen/src/xen_host.c	Tue Feb 20 22:46:21 2007 +0000
     3.3 @@ -1,5 +1,5 @@
     3.4  /*
     3.5 - * Copyright (c) 2006, XenSource Inc.
     3.6 + * Copyright (c) 2006-2007, XenSource Inc.
     3.7   *
     3.8   * This library is free software; you can redistribute it and/or
     3.9   * modify it under the terms of the GNU Lesser General Public
    3.10 @@ -160,37 +160,6 @@ xen_host_get_by_uuid(xen_session *sessio
    3.11  
    3.12  
    3.13  bool
    3.14 -xen_host_create(xen_session *session, xen_host *result, xen_host_record *record)
    3.15 -{
    3.16 -    abstract_value param_values[] =
    3.17 -        {
    3.18 -            { .type = &xen_host_record_abstract_type_,
    3.19 -              .u.struct_val = record }
    3.20 -        };
    3.21 -
    3.22 -    abstract_type result_type = abstract_type_string;
    3.23 -
    3.24 -    *result = NULL;
    3.25 -    XEN_CALL_("host.create");
    3.26 -    return session->ok;
    3.27 -}
    3.28 -
    3.29 -
    3.30 -bool
    3.31 -xen_host_destroy(xen_session *session, xen_host host)
    3.32 -{
    3.33 -    abstract_value param_values[] =
    3.34 -        {
    3.35 -            { .type = &abstract_type_string,
    3.36 -              .u.string_val = host }
    3.37 -        };
    3.38 -
    3.39 -    xen_call_(session, "host.destroy", param_values, 1, NULL, NULL);
    3.40 -    return session->ok;
    3.41 -}
    3.42 -
    3.43 -
    3.44 -bool
    3.45  xen_host_get_by_name_label(xen_session *session, struct xen_host_set **result, char *label)
    3.46  {
    3.47      abstract_value param_values[] =
     4.1 --- a/tools/python/xen/xend/XendAPI.py	Tue Feb 20 22:40:55 2007 +0000
     4.2 +++ b/tools/python/xen/xend/XendAPI.py	Tue Feb 20 22:46:21 2007 +0000
     4.3 @@ -680,8 +680,6 @@ class XendAPI(object):
     4.4          return xen_api_success(XendNode.instance().host_metrics_uuid)
     4.5  
     4.6      # object methods
     4.7 -    def host_destroy(self, session, host_ref):
     4.8 -        return xen_api_error(XEND_ERROR_UNSUPPORTED)    
     4.9      def host_disable(self, session, host_ref):
    4.10          XendDomain.instance().set_allow_new_domains(False)
    4.11          return xen_api_success_void()
    4.12 @@ -715,8 +713,6 @@ class XendAPI(object):
    4.13      # class methods
    4.14      def host_get_all(self, session):
    4.15          return xen_api_success((XendNode.instance().uuid,))
    4.16 -    def host_create(self, session, struct):
    4.17 -        return xen_api_error(XEND_ERROR_UNSUPPORTED)
    4.18      def host_get_by_name_label(self, session, name):
    4.19          if XendNode.instance().name == name:
    4.20              return xen_api_success((XendNode.instance().uuid,))