tibems_status

Type

Purpose

Functions return status codes to indicate return conditions.

Status Codes
Constant Code Description
TIBEMS_OK 0 The call completed normally.
TIBEMS_ILLEGAL_STATE 1 A function call or server request occurred in an inappropriate context.

For example, tibemsSession_Commit indicates this status when the session is non-transactional.

TIBEMS_INVALID_CLIENT_ID 2 The provider rejects the connection’s client ID.

Setting a connection’s client ID to an invalid or duplicate value results in this exception. (A duplicate value is one that is already in use by another connection.)

TIBEMS_INVALID_DESTINATION 3 tibemsd cannot locate the destination.
TIBEMS_INVALID_SELECTOR 4 The client passed a message selector with invalid syntax; see Message Selectors.
TIBEMS_EXCEPTION 5 Non-specific error code.
TIBEMS_SECURITY_EXCEPTION 6 The function cannot complete because of a security restriction.

For example, the provider rejects a user or the user’s authentication.

TIBEMS_MSG_EOF 7 The data stream within a message ended unexpectedly.

tibemsBytesMsg contains a stream of bytes. tibemsStreamMsg contains a stream of characters. If any of their read functions detects the end of a stream unexpectedly, it indicates this status.

TIBEMS_MSG_NOT_READABLE 9 Attempt to read from a message in write-only mode.
TIBEMS_MSG_NOT_WRITEABLE 10 Attempt to write to a message in read-only mode.

See also, tibemsMsg_MakeWriteable.

TIBEMS_SERVER_NOT_CONNECTED 11
  • An attempt to connect to the server has failed.
  • The operation requires a server connection, but the program is not connected.
TIBEMS_SUBJECT_COLLISION 13 The server cannot create a topic or durable because the name is already in use.
TIBEMS_INVALID_PROTOCOL 15 Cannot create a connection or transaction because the specified protocol does not exist.
TIBEMS_INVALID_HOSTNAME 17 The connection URL includes an invalid hostname, or an attempt to lookup the host address failed.

Host names must be less than 128 characters.

TIBEMS_INVALID_PORT 18 The connection URL includes an invalid port number.
TIBEMS_NO_MEMORY 19 The program exceeded available memory during the call.
TIBEMS_INVALID_ARG 20 The function received an illegal value as an argument.
TIBEMS_SERVER_LIMIT 21 The server has exceeded the maximum number of licensed connections or hosts that it can service.
TIBEMS_NOT_PERMITTED 27 The function call is not permitted (for example, closing a connection within a callback).
TIBEMS_SERVER_RECONNECTED 28 Exception callback handler functions receive this code to indicate that the server has reconnected.

See tibemsExceptionCallback

TIBEMS_INVALID_NAME 30 In a lookup request, the name has incorrect syntax.

The most common syntax error is a prefix other than tibjmsnaming:// (or a misspelling).

See also, tibemsLookupContext.

TIBEMS_INVALID_SIZE 32 An argument is outside the range of valid values.
TIBEMS_NOT_FOUND 35 1. The name lookup repository cannot find a name; the name is not bound. See also, tibemsLookupContext

2. A function that gets a message field or property value cannot find the specified item because the name is not bound in the message.

TIBEMS_CONVERSION_FAILED 38 A datatype conversion failed while parsing a message (converting UTF-8 data to native datatypes).
TIBEMS_INVALID_MSG 42 The message is uninitialized or corrupt.
TIBEMS_INVALID_FIELD 43 The message contains an invalid field. The message might be corrupt.
TIBEMS_CORRUPT_MSG 45 The message is corrupt.
TIBEMS_TIMEOUT 50 The timeout has expired while waiting for a message.

See tibemsMsgConsumer_ReceiveTimeout.

TIBEMS_INTR 51 A blocking operation has been interrupted. See tibemsMsgConsumer_Receive.
TIBEMS_DESTINATION_LIMIT_EXCEEDED 52 A server queue or topic has exceeded its size limit, and cannot add a new message.
TIBEMS_MEM_LIMIT_EXCEEDED 53 The server has exceeded its memory limit.
TIBEMS_USER_INTR 54 IBM z/OS only. A blocking operation has been interrupted. See tibx_MVSConsole_SetConsumer().
TIBEMS_INVALID_IO_SOURCE 65 The function detected an invalid I/O source (such as a socket or file).
TIBEMS_OS_ERROR 68 An operating system error occurred during the call.
TIBEMS_INSUFFICIENT_BUFFER 70 The result of the call overflowed the buffer supplied by the program.
TIBEMS_EOF 71 The call detected an unexpected end-of-file.
TIBEMS_INVALID_FILE 72 The function detected an invalid file.
TIBEMS_FILE_NOT_FOUND 73 The specified file does not exist.
TIBEMS_IO_FAILED 74 An operating system I/O call failed.
TIBEMS_ALREADY_EXISTS 91 Cannot create an item that already exists.
TIBEMS_INVALID_CONNECTION 100 The connection is invalid.
TIBEMS_INVALID_SESSION 101 The session is invalid.
TIBEMS_INVALID_CONSUMER 102 The consumer is invalid.
TIBEMS_INVALID_PRODUCER 103 The producer is invalid.
TIBEMS_INVALID_USER 104 The server could not authenticate the user.
TIBEMS_TRANSACTION_FAILED 106 A transaction failed at the server during a commit call.
TIBEMS_TRANSACTION_ROLLBACK 107 Failure during prepare or commit caused automatic rollback of a transaction. This type of rollback can occur during fault tolerance failover.
TIBEMS_TRANSACTION_RETRY 108 A transaction failed during two-phase commit; the program may attempt to commit it again.
TIBEMS_INVALID_XARESOURCE 109 When a session uses an XA transaction manager, the XA resource is the correct locus for all commit and rollback requests. Local commit or rollback calls are not permitted, and indicate this status.
TIBEMS_FT_SERVER_LACKS_TRANSACTION 110 The producer attempted to send a message immediately after a fault tolerance failover to another server. The new server has no record of the transaction.
TIBEMS_NOT_INITIALIZED 200 Initialization of the tibems library failed. For example, this code could be generated if the library failed to allocate memory while building its basic structures.
TLS
TIBEMS_INVALID_CERT 150 TLS detected an invalid X.509 certificate.
TIBEMS_INVALID_CERT_NOT_YET 151 TLS detected an X.509 certificate that is not yet valid; that is, the current date is before the first date for which the certificate becomes valid.
TIBEMS_INVALID_CERT_EXPIRED 152 TLS detected an X.509 certificate that is no longer valid; that is, the current date is after the expiration date.
TIBEMS_INVALID_CERT_DATA 153 TLS detected an X.509 certificate containing corrupt data.
TIBEMS_ALGORITHM_ERROR 154 Error loading a cipher suite algorithm.
TIBEMS_SSL_ERROR 155 Generic TLS error code.
TIBEMS_INVALID_PRIVATE_KEY 156 TLS detected a private key that does not match its public key.
TIBEMS_INVALID_ENCODING 157 TLS detected a certificate encoding that it cannot read.
TIBEMS_NOT_ENOUGH_RANDOM 158 TLS lacks sufficient random data to complete an operation securely.
Unimplemented
TIBEMS_NOT_IMPLEMENTED 255 The function is not implemented.