NdbError Struct Reference
Contains error information.
More...
#include <NdbError.hpp>
List of all members.
Public Types
- enum Status { Success = ndberror_st_success,
TemporaryError = ndberror_st_temporary,
PermanentError = ndberror_st_permanent,
UnknownResult = ndberror_st_unknown
}
- enum Classification {
NoError = ndberror_cl_none,
ApplicationError = ndberror_cl_application,
NoDataFound = ndberror_cl_no_data_found,
ConstraintViolation = ndberror_cl_constraint_violation,
SchemaError = ndberror_cl_schema_error,
UserDefinedError = ndberror_cl_user_defined,
InsufficientSpace = ndberror_cl_insufficient_space,
TemporaryResourceError = ndberror_cl_temporary_resource,
NodeRecoveryError = ndberror_cl_node_recovery,
OverloadError = ndberror_cl_overload,
TimeoutExpired = ndberror_cl_timeout_expired,
UnknownResultError = ndberror_cl_unknown_result,
InternalError = ndberror_cl_internal_error,
FunctionNotImplemented = ndberror_cl_function_not_implemented,
UnknownErrorCode = ndberror_cl_unknown_error_code,
NodeShutdown = ndberror_cl_node_shutdown,
SchemaObjectExists = ndberror_cl_schema_object_already_exists,
InternalTemporary = ndberror_cl_internal_temporary
}
Public Attributes
Detailed Description
Contains error information.
A NdbError consists of five parts:
- Error status : Application impact
- Error classification : Logical error group
- Error code : Internal error code
- Error message : Context independent description of error
- Error details : Context dependent information (not always available)
Error status is usually used for programming against errors. If more detailed error control is needed, it is possible to use the error classification.
It is not recommended to write application programs dependent on specific error codes.
The error messages and error details may change without notice.
For example of use, see ndbapi_retries.cpp.
Member Enumeration Documentation
Type of error
- Enumerator:
-
NoError |
Success. No error occurred. |
ApplicationError |
Error in application program. |
NoDataFound |
Read operation failed due to missing record. |
ConstraintViolation |
E.g. inserting a tuple with a primary key already existing in the table. |
SchemaError |
Error in creating table or usage of table. |
UserDefinedError |
Error occurred in interpreted program. |
InsufficientSpace |
E.g. insufficient memory for data or indexes. |
TemporaryResourceError |
E.g. too many active transactions. |
NodeRecoveryError |
Temporary failures which are probably inflicted by a node recovery in progress. Examples: information sent between application and NDB lost, distribution change. |
OverloadError |
E.g. out of log file space. |
TimeoutExpired |
Timeouts, often inflicted by deadlocks in NDB. |
UnknownResultError |
Is is unknown whether the transaction was committed or not. |
InternalError |
A serious error in NDB has occurred. |
FunctionNotImplemented |
A function used is not yet implemented. |
UnknownErrorCode |
Error handler could not determine correct error code. |
NodeShutdown |
Node shutdown |
SchemaObjectExists |
Schema object already exists |
InternalTemporary |
Request sent to non master |
Status categorizes error codes into status values reflecting what the application should do when encountering errors
- Enumerator:
-
Success |
The error code indicate success
(Includes classification: NdbError::NoError) |
TemporaryError |
The error code indicates a temporary error. The application should typically retry.
(Includes classifications: NdbError::InsufficientSpace, NdbError::TemporaryResourceError, NdbError::NodeRecoveryError, NdbError::OverloadError, NdbError::NodeShutdown and NdbError::TimeoutExpired.) |
PermanentError |
The error code indicates a permanent error.
(Includes classificatons: NdbError::PermanentError, NdbError::ApplicationError, NdbError::NoDataFound, NdbError::ConstraintViolation, NdbError::SchemaError, NdbError::UserDefinedError, NdbError::InternalError, and, NdbError::FunctionNotImplemented.) |
UnknownResult |
The result/status is unknown.
(Includes classifications: NdbError::UnknownResultError, and NdbError::UnknownErrorCode.) |
Member Data Documentation
The detailed description. This is extra information regarding the error which is not included in the error message.
- Note:
- Is NULL when no details specified