libstoragemgmt_error.h File Reference

#include "libstoragemgmt_common.h"
Include dependency graph for libstoragemgmt_error.h:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Typedefs

typedef struct _lsm_error lsm_error
typedef lsm_errorlsm_error_ptr

Enumerations

enum  lsm_error_number {
  LSM_ERR_OK = 0, LSM_ERR_LIB_BUG = 1, LSM_ERR_PLUGIN_BUG = 2, LSM_ERR_JOB_STARTED = 7,
  LSM_ERR_TIMEOUT = 11, LSM_ERR_DAEMON_NOT_RUNNING = 12, LSM_ERR_NAME_CONFLICT = 50, LSM_ERR_EXISTS_INITIATOR = 52,
  LSM_ERR_INVALID_ARGUMENT = 101, LSM_ERR_NO_STATE_CHANGE = 125, LSM_ERR_NETWORK_CONNREFUSED = 140, LSM_ERR_NETWORK_HOSTDOWN = 141,
  LSM_ERR_NETWORK_ERROR = 142, LSM_ERR_NO_MEMORY = 152, LSM_ERR_NO_SUPPORT = 153, LSM_ERR_IS_MASKED = 160,
  LSM_ERR_NOT_FOUND_ACCESS_GROUP = 200, LSM_ERR_NOT_FOUND_FS = 201, LSM_ERR_NOT_FOUND_JOB = 202, LSM_ERR_NOT_FOUND_POOL = 203,
  LSM_ERR_NOT_FOUND_FS_SS = 204, LSM_ERR_NOT_FOUND_VOLUME = 205, LSM_ERR_NOT_FOUND_NFS_EXPORT = 206, LSM_ERR_NOT_FOUND_SYSTEM = 208,
  LSM_ERR_NOT_FOUND_DISK = 209, LSM_ERR_NOT_LICENSED = 226, LSM_ERR_NO_SUPPORT_ONLINE_CHANGE = 250, LSM_ERR_NO_SUPPORT_OFFLINE_CHANGE = 251,
  LSM_ERR_PLUGIN_AUTH_FAILED = 300, LSM_ERR_PLUGIN_IPC_FAIL = 301, LSM_ERR_PLUGIN_SOCKET_PERMISSION = 307, LSM_ERR_PLUGIN_NOT_EXIST = 311,
  LSM_ERR_NOT_ENOUGH_SPACE = 350, LSM_ERR_TRANSPORT_COMMUNICATION = 400, LSM_ERR_TRANSPORT_SERIALIZATION = 401, LSM_ERR_TRANSPORT_INVALID_ARG = 402,
  LSM_ERR_LAST_INIT_IN_ACCESS_GROUP = 502, LSM_ERR_UNSUPPORTED_SEARCH_KEY = 510, LSM_ERR_EMPTY_ACCESS_GROUP = 511, LSM_ERR_POOL_NOT_READY = 512,
  LSM_ERR_DISK_NOT_FREE = 513
}

Functions

lsm_error_ptr LSM_DLL_EXPORT lsm_error_last_get (lsm_connect *c)
int LSM_DLL_EXPORT lsm_error_free (lsm_error_ptr err)
lsm_error_number LSM_DLL_EXPORT lsm_error_number_get (lsm_error_ptr e)
char LSM_DLL_EXPORT * lsm_error_message_get (lsm_error_ptr e)
char LSM_DLL_EXPORT * lsm_error_exception_get (lsm_error_ptr e)
char LSM_DLL_EXPORT * lsm_error_debug_get (lsm_error_ptr e)
void LSM_DLL_EXPORT * lsm_error_debug_data_get (lsm_error_ptr e, uint32_t *size)

Detailed Description

Definition in file libstoragemgmt_error.h.


Typedef Documentation

typedef struct _lsm_error lsm_error

Definition at line 137 of file libstoragemgmt_error.h.

Definition at line 138 of file libstoragemgmt_error.h.


Enumeration Type Documentation

< Possible enumerated return codes from library

Enumerator:
LSM_ERR_OK 
LSM_ERR_LIB_BUG 

^ OK

LSM_ERR_PLUGIN_BUG 

^ Library BUG

LSM_ERR_JOB_STARTED 

^ Plugin BUG

LSM_ERR_TIMEOUT 

^ Operation has started

LSM_ERR_DAEMON_NOT_RUNNING 

^ Plug-in is un-responsive

LSM_ERR_NAME_CONFLICT 

^ Daemon is not running

LSM_ERR_EXISTS_INITIATOR 

^ Name exists

LSM_ERR_INVALID_ARGUMENT 

^ Initiator exists in another access group

LSM_ERR_NO_STATE_CHANGE 

^ Precondition checks failed

LSM_ERR_NETWORK_CONNREFUSED 

^ Operation completed with no change in array state

LSM_ERR_NETWORK_HOSTDOWN 

^ Host on network, but not allowing connection

LSM_ERR_NETWORK_ERROR 

^ Host unreachable on network

LSM_ERR_NO_MEMORY 

^ Generic network error

LSM_ERR_NO_SUPPORT 

^ Memory allocation failure

LSM_ERR_IS_MASKED 

^ Feature not supported

LSM_ERR_NOT_FOUND_ACCESS_GROUP 

^ Volume masked to Access Group

LSM_ERR_NOT_FOUND_FS 

^ Specified access group not found

LSM_ERR_NOT_FOUND_JOB 

^ Specified FS not found

LSM_ERR_NOT_FOUND_POOL 

^ Specified JOB not found

LSM_ERR_NOT_FOUND_FS_SS 

^ Specified POOL not found

LSM_ERR_NOT_FOUND_VOLUME 

^ Specified snap shot not found

LSM_ERR_NOT_FOUND_NFS_EXPORT 

^ Specified volume not found

LSM_ERR_NOT_FOUND_SYSTEM 

^ NFS export not found

LSM_ERR_NOT_FOUND_DISK 

^ System not found

LSM_ERR_NOT_LICENSED 
LSM_ERR_NO_SUPPORT_ONLINE_CHANGE 

^ Need license for feature

LSM_ERR_NO_SUPPORT_OFFLINE_CHANGE 

^ Take offline before performing operation

LSM_ERR_PLUGIN_AUTH_FAILED 

^ Needs to be online to perform operation

LSM_ERR_PLUGIN_IPC_FAIL 

^ Authorization failed

LSM_ERR_PLUGIN_SOCKET_PERMISSION 

^ Inter-process communication between client & out of process plug-in encountered connection errors.

LSM_ERR_PLUGIN_NOT_EXIST 

^ Incorrect permission on UNIX domain socket used for IPC

LSM_ERR_NOT_ENOUGH_SPACE 

^ Plug-in does not appear to exist

LSM_ERR_TRANSPORT_COMMUNICATION 

^ Insufficient space

LSM_ERR_TRANSPORT_SERIALIZATION 

^ Error comunicating with plug-in

LSM_ERR_TRANSPORT_INVALID_ARG 

^ Transport serialization error

LSM_ERR_LAST_INIT_IN_ACCESS_GROUP 

^ Parameter transported over IPC is invalid

LSM_ERR_UNSUPPORTED_SEARCH_KEY 
LSM_ERR_EMPTY_ACCESS_GROUP 

^ Unsupport search key

LSM_ERR_POOL_NOT_READY 
LSM_ERR_DISK_NOT_FREE 

Definition at line 33 of file libstoragemgmt_error.h.


Function Documentation

void LSM_DLL_EXPORT* lsm_error_debug_data_get ( lsm_error_ptr  e,
uint32_t *  size 
)

Retrieves the debug data from the error. Note: The returned value is only valid as long as the e is valid, in addition the function will return NULL if e is invalid. To remove the ambiguity call lsm_error_number_get and check return code.

Parameters:
e The lsm_error_ptr
[out] size Number of bytes of data returned.
Returns:
NULL if does not exist, else debug message.

Definition at line 433 of file lsm_datatypes.cpp.

char LSM_DLL_EXPORT* lsm_error_debug_get ( lsm_error_ptr  e  ) 

Retrieves the error message from the error. Note: The returned value is only valid as long as the e is valid, in addition the function will return NULL if e is invalid. To remove the ambiguity call lsm_error_number_get and check return code.

Parameters:
e The lsm_error_ptr
Returns:
NULL if does not exist, else debug message.

Definition at line 428 of file lsm_datatypes.cpp.

char LSM_DLL_EXPORT* lsm_error_exception_get ( lsm_error_ptr  e  ) 

Retrieves the exception message from the error. Note: The returned value is only valid as long as the e is valid, in addition the function will return NULL if e is invalid. To remove the ambiguity call lsm_error_number_get and check return code.

Parameters:
e The lsm_error_ptr
Returns:
NULL if exception does not exist, else error exception.

Definition at line 423 of file lsm_datatypes.cpp.

int LSM_DLL_EXPORT lsm_error_free ( lsm_error_ptr  err  ) 

Frees the error record!

Parameters:
err The error to free!
Returns:
LSM_ERR_OK on success, else error reason.

Definition at line 373 of file lsm_datatypes.cpp.

Here is the caller graph for this function:

lsm_error_ptr LSM_DLL_EXPORT lsm_error_last_get ( lsm_connect c  ) 

Gets the last error structure Note:

See also:
lsm_error_free to release memory
Parameters:
c Connection pointer.
Returns:
Error pointer, Null if no error exists!

Here is the caller graph for this function:

char LSM_DLL_EXPORT* lsm_error_message_get ( lsm_error_ptr  e  ) 

Retrieves the error message from the error. Note: The returned value is only valid as long as the e is valid, in addition the function will return NULL if e is invalid. To remove the ambiguity call lsm_error_number_get and check return code.

Parameters:
e The lsm_error_ptr
Returns:
NULL if message data does not exist, else error message.

Definition at line 418 of file lsm_datatypes.cpp.

Here is the caller graph for this function:

lsm_error_number LSM_DLL_EXPORT lsm_error_number_get ( lsm_error_ptr  e  ) 

Retrieves the error number from the error.

Parameters:
e The lsm_error_ptr
Returns:
-1 if e is not a valid error pointer, else error number.

Definition at line 413 of file lsm_datatypes.cpp.


Generated on 9 Jul 2015 for libStorageMgmt by  doxygen 1.6.1