Berkeley DB: DbEnv::set_lk_detect
Description: Berkeley DB: An embedded database programmatic toolkit.
Keywords: embedded,database,programmatic,toolkit,b+tree,btr ee,hash,hashing,transaction,transactions,locking,logging,access method,access me thods,java,C,C++

# DbEnv::set_lk_detect

`

###

    #include <db_cxx.h>

    void DbEnv::set_lk_detect(u_int32_t);

# Description

Set if the deadlock detector is to be run whenever a lock conflict occurs, and specifies which transaction should be aborted in the case of a deadlock. The specified value must be one of the following list:

DB_LOCK_DEFAULT
  Use the default policy as specified by db_deadlock.

DB_LOCK_OLDEST
  Abort the oldest transaction.

DB_LOCK_RANDOM
  Abort a random transaction involved in the deadlock.

DB_LOCK_YOUNGEST
  Abort the youngest transaction.

# Class

DbEnv

# See Also

DbEnv::appinit, DbEnv::appexit, DbEnv::version, DbEnv::get_lg_info, DbEnv::get_lk_info, DbEnv::get_mp_info, DbEnv::get_tx_info, dbenv_set_data_dir, DbEnv::set_errcall, DbEnv::set_errfile, DbEnv::set_error_model, DbEnv::set_error_stream, DbEnv::set_errpfx, DbEnv::set_lg_max, DbEnv::set_lk_conflicts, DbEnv::set_lk_detect, DbEnv::set_lk_modes, DbEnv::set_lorder, DbEnv::set_mp_mmapsize, DbEnv::set_mp_size, DbEnv::set_tx_max, DbEnv::set_tx_recover and DbEnv::set_verbose.`