Type alias TransactionOptions

TransactionOptions: {
    allowDirtyRead?: boolean;
    allowImplicit?: boolean;
    lockTimeout?: number;
    maxTransactionSize?: number;
    skipFastLockRound?: boolean;
    waitForSync?: boolean;
}

Options for how the transaction should be performed.

Type declaration

  • Optional allowDirtyRead?: boolean

    If set to true, the request will explicitly permit ArangoDB to return a potentially dirty or stale result and arangojs will load balance the request without distinguishing between leaders and followers.

  • Optional allowImplicit?: boolean

    Whether the transaction may read from collections not specified for this transaction. If set to false, accessing any collections not specified will result in the transaction being aborted to avoid potential deadlocks.

    Default: true.

  • Optional lockTimeout?: number

    Determines how long the database will wait while attempting to gain locks on collections used by the transaction before timing out.

  • Optional maxTransactionSize?: number

    Determines the transaction size limit in bytes.

  • Optional skipFastLockRound?: boolean

    If set to true, the fast lock round will be skipped, which makes each locking operation take longer but guarantees deterministic locking order and may avoid deadlocks when many concurrent transactions are queued and try to access the same collection with an exclusive lock.

  • Optional waitForSync?: boolean

    Determines whether to force the transaction to write all data to disk before returning.