C++ API Reference

Chapter 5

Predefined TIX Exceptions

This chapter contains information on significant predefined exceptions. These exceptions are defined in client.hh and ostore.hh, so they are available to your programs automatically.

Parent Exceptions

The following are parents in the exceptions object tree hierarchy. They are never signaled directly, but they are useful when establishing a TIX exception handler for them to catch a group of exceptions. See TIX_HANDLE().

ObjectStore exceptions object tree hierarchy
The hierarchy is arranged as follows:

General ObjectStore Exceptions

The following exceptions are all descended from err_objectstore.

err_abort_committed

err_address_space_full - Address space is full.

err_alignment - A memory fault was signaled by the operating system, but rather than the usual access fault, this fault indicates that there was an alignment error. Often this means that there was an attempt to dereference through a pointer whose value is odd.

err_architecture_mismatch - The architecture of the database is not compatible with that of the application.

err_authentication_failure

err_awaiting_recovery - The Server cannot perform this operation, ultimately because some Server is down and needs to be brought back up, specifically because it operates on a block that is tied up because of a two-phase commit that is still in progress because of the Server crash. Check the console messages to see explanatory messages from the two-phase commit recovery procedure.

err_beyond_segment_length - Several meanings, most commonly that the client sent a block number that was higher than the highest block in the segment.

err_broken_server_connection - This usually means the same thing as err_network_failure and might mean network trouble or that the Server has crashed; see the class os_server. This exception can also occur if a client is attempting to communicate with an incompatible server (for example, the server and client are from different, incompatible releases of ObjectStore).

err_cache_manager_not_responding - The Server was unable to form a network connection to the Cache Manager process of your client host. You should see whether the Cache Manager process appears to be alive; if it is not, look in the operating system error log for an error message that might help explain what happened to the Cache Manager.

err_cannot_commit - ObjectStore tried to perform a commit involving updates to multiple servers (that is, a two-phase commit) and it cannot determine a common network for communications.

err_cannot_open_application_schema - This is signaled if you try to create or look up a database, but the application schema database for your application cannot be found.

err_checkpoint_aborted

err_checkpoint_committed

err_checkpoint_not_inner

err_cluster_full - Signaled by an attempt to allocate storage in a cluster that does not have enough room for the specified object.

err_cluster_is_deleted - Most commonly signaled when an operation was attempted on a cluster that has been deleted or is believed not to exist.

err_cluster_mismatch

err_cluster_transient - Signaled when the user attempts to perform an operation that is not legal for transient clusters.

err_commit_aborted

err_commit_abort_only - Signaled when the user attempts to commit an abort-only transaction.

err_commit_with_children

err_conflicting_failover_configuration

err_connection_closed

err_cross_db_pointer - A pointer from one database to another was found. This happens only if external pointers are not allowed. See, for example, os_database::allow_external_pointers().

err_cursor_at_end

err_cursor_not_at_object

err_database_exists - The database already exists. This can happen only from mkdir.

err_database_id_exists - The client requested the Server to create a new database with a certain database ID, but the Server found that a database with that database ID already exists. Ordinarily, the Server invents a new database ID, so this cannot happen. The error can occur when the client side specifies a particular database ID, which typically happens only when you are reloading a backup tape or using the osdbimport utility.

err_database_id_not_found - Several meanings, most commonly that the database_handle sent by the client was not valid.

err_database_is_deleted - The database has been deleted.

errr__database_lock_conflict

err_database_not_found - The specified database was not found. For example, the application tried to look up /a/b/c, but the directory /a/b did not contain a database named c.

err_database_not_open - The database is not open. Signaled by the notification APIs.

err_database_not_open_update - Signaled when the database open mode is not update; the mode could be read-only or MVCC.

err_database_transient - This operation is not allowed on the transient database. Signaled by the notification APIs.

err_database_wrong_version - Currently, there is only one version of database format, so this exception cannot be signaled. In the future, however, the format of databases might change. This exception is signaled if an executable file linked with an older version of ObjectStore that cannot understand the new format attempts to operate on a database in the new format.

err_datagram_error

err_db_cannot_change_open - Signaled when the user attempts to open a database that is already open in a different open mode.

err_default_cluster - Cluster cannot be assigned as the default cluster. It can be a huge cluster, or it might not be in the specified segment.

err_default_segment - Segment cannot be assigned as the default segment. It can be the system segment or it might not be in the specified database.

err_deadlock - A deadlock was detected. Note that ObjectStore transactions establish handlers for this exception.

err_deref_transient_pointer - An attempt was made to dereference a pointer to transient memory. The operating system signaled a virtual memory access fault, but the address of the fault was within the transient area of the address space, rather than within the persistent area.

err_directory_exists - This is signaled by objectstore::make_directories or objectstore::mkdir when you try to make a new directory on the Directory Manager but a directory with that name already exists.

err_directory_not_empty - The directory was not empty, but the application tried to delete the directory. This can happen only from mkdir.

err_directory_not_found - The specified pathname contained a directory component that was not found.

err_explicit_commit_stack_txn

err_file_error

err_file_not_db

err_file_not_local - You have asked a Server to operate on a file database that is stored not on that Server host but on another host that the Server host has mounted using NFS. This should be possible only if you specify a Server explicitly for file databases, which is not the usual way file databases are used.

err_file_pathname - An entry point has checked a pathname and signaled that it is a file pathname rather than a rawfs pathname.

err_hardware - A memory fault was signaled by the operating system, but rather than the usual access fault, this fault indicates that there was a hardware error, such as a memory bus timeout.

err_inconsistent_db

err_illegal_acquire_lock

err_indigestible_pna

err_insufficient_virtual_memory - malloc space is used up.

err_internal - Several possible meanings: (1) The client did a RELEASE_BLOCKS on a block it does not own; (2) The client sent a block number that was higher than the highest block in the segment; (3) The database_handle sent by the client was not valid; and (4) An operation was done on a segment that has been deleted or is believed not to exist. Note that you cannot handle err_internal.

err_invalid_deletion - An argument that was not a pointer to a persistent object was passed to operator delete.

err_invalid_pathname - A syntactically invalid pathname was specified.

err_invalid_root_value - You have tried to store a transient or a cross-database pointer in a root.

err_license_limit - No connections are available, due to licensing limitations. This refers to the maximum number of connections, as specified by the Server password file.

err_link_not_found - Intrarawfs link was not found.

err_locator_file_id

err_locator_read_only

err_locator_syntax

err_lock_timeout

err_misc - Specific to notifications are as follows:

err_mvcc_nested

err_net_cant_connect

err_net_connect_timeout

err_net_connection_refused

err_net_host_down

err_net_no_server

err_network

err_network_failure - The network connection failed, possibly due to network trouble, or because the Server or Directory Manager crashed.

err_no_credentials - Access is not permitted; no credentials were presented.

err_no_query_trans

err_no_rawfs - There is no rawfs on the Server.

err_no_service_on_net

err_no_such_host - The specified host does not exist.

err_no_trans - There is no transaction in progress.

err_not_a_database - The pathname is not the pathname of a database. For example, the application tried to delete a database called /a/b, but /a/b was a directory.

err_not_a_directory - A pathname that was expected to be a directory is something else, possibly a database.

err_not_assigned - No database is assigned to the specified location. The application dereferenced a pointer that pointed into an area of virtual memory used for persistent objects but which was not a valid location. It was not valid because no database was mapped to the specified address. Typically this means that the application saved a pointer from a previous transaction, then used it in a subsequent transaction, which is not allowed.

err_null_pointer - An attempt was made to dereference a null (zero) pointer.

err_operation_not_supported

err_operator_new_args - Invalid arguments were specified for ObjectStore's operator new. Currently, this can happen only if you try to pass 0 to operator new as the count argument.

err_os_compaction - Invalid arguments to objectstore::compact().

err_permission_denied - Permission to access this database was denied.

err_prepare_to_commit

err_protocol_not_supported - The ObjectStore client and server (or cache manager) do not agree on the communication protocol to be used between them. One reason for the protocol incompatibility could be that the client and server are from different releases of ObjectStore.

err_rawfs_not_upgraded - The rawfs is from an old release.

err_read_only_file_system - The file database is stored in a read-only file system.

err_reference_not_found - An attempt was made to resolve an object that has been deleted. This can happen to any safe reference, or to an unsafe reference when the target segment has been deleted.

err_reference_syntax - A string with improper syntax was passed to the load() member of a reference class.

err_reference_to_transient - The application attempted to create a safe reference to a transient location, which is not allowed.

err_restartable

err_root_exists - A root with the specified name already exists. This occurs only if you create a root explicitly; it cannot happen as a result of implicit root creation by persistent variables.

err_schema_database - Attempt to use a closed database as a schema database, or attempt to use as a schema database a database that itself stored its schema remotely.

err_schema_validation_error - An error occurred during schema validation.

err_schema_validation_failed - The schema could not be validated.

err_segment_is_deleted - Several meanings, most commonly that an operation was done on a segment that has been deleted or is believed not to exist.

err_segment_transient - Signaled when the user attempts to perform an operation that is not legal for transient segments. For example, this error is signaled if you attempt to create a cluster in a transient segment; see os_segment::create_cluster().

err_server_address_in_use

err_server_cannot_open_cache - The Server, running on the same host as the client, could not open the cache file to use shared memory transfers.

err_server_full - The Server has run out of disk space.

err_server_not_superuser - The Server is not running as the superuser.

err_server_refused_connection - The Server refused to make the requested connection.

err_server_restarted

err_string_too_long - Notification string is longer than 16,383 characters.

err_too_many_cross_svr_links - Excessively long cross-Server link chain. The maximum depth of a cross-Server link chain is currently 15.

err_too_many_links - Too many levels of intrarawfs links.

err_too_many_retries - The transaction was retried more times than the value specified by os_transaction::max_retries.

err_trans - An operation was performed outside a transaction when it should have been within one, or an operation was performed within a transaction when it should have been outside any transaction. For example, an attempt was made to access persistent memory from outside any transaction.

err_transient_pointer - A transient pointer was found in a database.

err_trans_wrong_type - An attempt was made to start a nested transaction whose type (update or read_only) differs from the type of the transaction within which it is nested.

err_typespec_mismatch - A persistent variable type mismatch was detected. This happens if two applications use a database; the first has a persistent variable with a particular name and type, and the second has a persistent variable with the same name but with a different type.

err_uninitialized - This error should not occur. It means the database is uninitialized, possibly because the application that created the database aborted before it finished running, leaving the database empty and not yet initialized. If this occurs, you should delete the database and recreate it.

err_unknown_pointer - While pointers were being relocated, ObjectStore came upon a pointer that did not seem to be a valid pointer to any object.

err_user_aborted_simple_authentication.

err_write_during_query - An attempt was made to write during a read-only transaction. Write refers not only to storing into persistent objects but also to other operations that modify the database, such as creating segments.

err_write_permission_denied - Permission to write this database was denied.

Schema Evolution Exceptions

The following exceptions are all descended from err_schema_evolution, which is a descendant of err_objectstore.

err_se_ambiguous_subtype_evolution - An attempt was made to evolve an object to a subtype in which it is not a unique supertype.

err_se_ambiguous_void_pointer - A void pointer was specified that could not be interpreted unambiguously. This is the case when there are nested data that occupy the same location before schema evolution but different locations afterward.

err_se_cannot_delete_class - The specified class cannot be deleted from the schema because other classes still depend upon it.

err_se_cross_database_pointer - An attempt was made to resolve a cross-database pointer to a database that was not part of the set of databases being evolved.

err_se_deleted_component - A pointer was specified to the deleted component of a valid object.

err_se_deleted_object - A pointer was specified to a deleted object.

err_se_illegal_pointer - This is the base type for various illegal pointers.

err_se_invalid_subtype_evolution - An attempt was made to evolve an object to a type that was not a subtype.

err_se_pointer_type_mismatch

err_se_transient_object - A pointer to a transient object was encountered.

err_se_unnecessary - The requested schema evolution was unnecessary; all schemas under consideration are compatible.

Metaobject Protocol Exceptions

The following exceptions are descended from err_mop, which is a descendent of err_objectstore.

err_mop

err_mop_forward_definition - An attempt was made to access information about a class for which only a forward definition exists, and the information required a full definition.

err_mop_illegal_cast - An attempt was made to cast a metaobject to an inappropriate type.

RPC Exceptions

The following exceptions are children of err_rpc. They rarely are signaled; only the most common ones are described in detail in the following list:

err_rpc_cantrecv - The operating system signaled an error when ObjectStore tried to receive data. The textual message from the operating system is included in the character-string report in the exception.

err_rpc_cantsend - The operating system signaled an error when ObjectStore tried to send data. The textual message from the operating system is included in the character-string report in the exception.

err_rpc_timedout - The Server or the Directory Manager timed out; that is, the client was waiting for a reply, and after a certain fixed amount of time, did not receive one. This can mean, among other things, that the Server or Directory Manager has crashed, that it is slow to respond, or that the network is not working properly.

err_rpc_auth_badcred

err_rpc_auth_badverf

err_rpc_autherror

err_rpc_auth_failed

err_rpc_auth_invalidresp

err_rpc_auth_ok

err_rpc_auth_rejectedcred

err_rpc_auth_rejectedverf

err_rpc_auth_tooweak

err_rpc_cantdecodeargs

err_rpc_cantdecoderes

err_rpc_cantencodeargs

err_rpc_failed

err_rpc_pmapfailure

err_rpc_procunavail

err_rpc_prognotregistered

err_rpc_progunavail

err_rpc_progversmismatch

err_rpc_success

err_rpc_systemerror

err_rpc_unknownhost

err_rpc_unknownproto

err_rpc_versmismatch

Component Schema Exceptions

The following exceptions exist:
err_schema_not_loaded

"The program schema must be loaded before doing this operation"

err_schema_not_found

"The specified program schema was not found"

err_bad_schema_info

"The program schema info being loaded is invalid"

err_invalid_for_application_schema

"This operation is invalid for the application schema"

err_cannot_open_DLL_schema

"Unable to open DLL schema database"

err_transient_dope_damaged

"Some objects' transient dope could be invalid"

err_DLL

"Operating system DLL operation failed"

err_DLL_not_loaded

"Shared library could not be loaded"

err_DLL_not_unloaded

"Shared library could not be unloaded"

err_DLL_symbol_not_found

"Symbol could not be found in shared library"



[previous]

Copyright © 1999 Object Design, Inc. All rights reserved.

Updated: 03/15/99 16:44:39