WARNING - OLD ARCHIVES

This is an archived copy of the Xen.org mailing list, which we have preserved to ensure that existing links to archives are not broken. The live archive, which contains the latest emails, can be found at http://lists.xen.org/

 Home Products Support Community News

xen-changelog

[Xen-changelog] [xen-unstable] Document a few error codes.

 To: xen-changelog@xxxxxxxxxxxxxxxxxxx [Xen-changelog] [xen-unstable] Document a few error codes. Xen patchbot-unstable Thu, 21 Dec 2006 09:05:20 -0800 Thu, 21 Dec 2006 09:06:49 -0800 www-data@xxxxxxxxxxxxxxxxxx BK change log , , xen-devel@xxxxxxxxxxxxxxxxxxx xen-changelog-bounces@xxxxxxxxxxxxxxxxxxx
 # HG changeset patch # User Ewan Mellor # Date 1166706729 0 # Node ID 38213c2544d769ccc3fc6ad2fe432a65ea61de36 # Parent d5677481f2431b6cd111020bde1ef4925ae78197 Document a few error codes. Signed-off-by: Ewan Mellor --- docs/xen-api/xenapi-datamodel.tex | 112 ++++++++++++++++++++++++++++++++++++++ 1 files changed, 112 insertions(+) diff -r d5677481f243 -r 38213c2544d7 docs/xen-api/xenapi-datamodel.tex --- a/docs/xen-api/xenapi-datamodel.tex Thu Dec 21 13:11:24 2006 +0000 +++ b/docs/xen-api/xenapi-datamodel.tex Thu Dec 21 13:12:09 2006 +0000 @@ -10428,6 +10428,118 @@ all fields from the object \vspace{0.3cm} \vspace{1cm} +\newpage +\section{Error Handling} +When a low-level transport error occurs, or a request is malformed at the HTTP +or XML-RPC level, the server may send an XML-RPC Fault response, or the client +may simulate the same. The client must be prepared to handle these errors, +though they may be treated as fatal. On the wire, these are transmitted in a +form similar to this: + +\begin{verbatim} + + + + + + faultCode + -1 + + + faultString + Malformed request + + + + + +\end{verbatim} + +All other failures are reported with a more structured error response, to +allow better automatic response to failures, proper internationalisation of +any error message, and easier debugging. On the wire, these are transmitted +like this: + +\begin{verbatim} + + + Status + Failure + + + ErrorDescription + + + + MAP_DUPLICATE_KEY + Customer + eSpeil Inc. + eSpeil Incorporated + + + + + +\end{verbatim} + +Note that {\tt ErrorDescription} value is an array of string values. The +first element of the array is an error code; the remainder of the array are +strings representing error parameters relating to that code. In this case, +the client has attempted to add the mapping {\tt Customer $\rightarrow$ +eSpiel Incorporated} to a Map, but it already contains the mapping +{\tt Customer $\rightarrow$ eSpiel Inc.}, and so the request has failed. + +Each possible error code is documented in the following section. + +\subsection{Error Codes} + +\vspace{0.9cm} +\subsubsection{MAP\_DUPLICATE\_KEY} + +You tried to add a key-value pair to a map, but that key is already there. +The key, current value, and the new value that you tried to set are all +echoed. + +\vspace{0.3cm} +\noindent{\bf Signature:} +\begin{verbatim}MAP_DUPLICATE_KEY(key, current value, new value)\end{verbatim} + + +\vspace{0.9cm} +\subsubsection{INTERNAL\_ERROR} + +The server failed to handle your request, due to an internal error. The +given message may give details useful for debugging the problem. + +\vspace{0.3cm} +\noindent{\bf Signature:} +\begin{verbatim}INTERNAL_ERROR(message)\end{verbatim} + + +\vspace{0.9cm} +\subsubsection{SESSION\_INVALID} + +You gave an invalid session handle. It may have been invalidated by a +server restart, or timed out. You should get a new session handle, using +one of the session.login\_ calls. This error does not invalidate the +current connection. The handle parameter echoes the bad value given. + +\vspace{0.3cm} +\noindent{\bf Signature:} +\begin{verbatim}SESSION_INVALID(handle)\end{verbatim} + + +\vspace{0.9cm} +\subsubsection{VM\_HANDLE\_INVALID} + +You gave an invalid VM handle. The VM may have recently been deleted. The +handle parameter echoes the bad value given. + +\vspace{0.3cm} +\noindent{\bf Signature:} +\begin{verbatim}VM_HANDLE_INVALID(handle)\end{verbatim} + +\newpage \section{DTD} General notes: \begin{itemize} _______________________________________________ Xen-changelog mailing list Xen-changelog@xxxxxxxxxxxxxxxxxxx http://lists.xensource.com/xen-changelog 
 Current Thread [Xen-changelog] [xen-unstable] Document a few error codes., Xen patchbot-unstable <=