StreamTransaction
extends Transaction
in package
FinalYes
Manages stream transactions on ArangoDB server
Table of Contents
Properties
- $connection : Connection
- Connection object
- $defaultOptions : array<string|int, mixed>
- Some default options for transaction Sets by default, 32MB as transaction size limit and waits server write all data on disk before return any response.
- $id : string
- Transaction Id
- $options : array<string|int, mixed>
- StreamTransaction options
- $started : bool
- If the transaction object is already started
- $status : string
- Transaction status
Methods
- __construct() : mixed
- StreamTransaction constructor.
- abort() : void
- Abort transaction
- begin() : void
- Begin transaction
- commit() : void
- Commit transaction
- getTransactionId() : string
- Returns the transaction id
- getTransactionStatus() : string
- Returns the transaction status
Properties
$connection
Connection object
protected
Connection
$connection
$defaultOptions
Some default options for transaction Sets by default, 32MB as transaction size limit and waits server write all data on disk before return any response.
protected
array<string|int, mixed>
$defaultOptions
= ['maxTransactionSize' => 32000000, 'waitForSync' => true, 'allowImplicit' => false, 'lockTimeout' => 30]
Also, set by default a lock timeout of 30 seconds.
$id
Transaction Id
protected
string
$id
$options
StreamTransaction options
protected
array<string|int, mixed>
$options
$started
If the transaction object is already started
protected
bool
$started
= false
$status
Transaction status
protected
string
$status
= ''
Methods
__construct()
StreamTransaction constructor.
public
__construct(Connection $connection[, array<string|int, mixed> $options = [] ]) : mixed
Parameters
- $connection : Connection
-
Connection object to use.
- $options : array<string|int, mixed> = []
-
Transaction options.
Tags
abort()
Abort transaction
public
abort() : void
Tags
begin()
Begin transaction
public
begin() : void
Tags
commit()
Commit transaction
public
commit() : void
Tags
getTransactionId()
Returns the transaction id
public
getTransactionId() : string
Return values
stringgetTransactionStatus()
Returns the transaction status
public
getTransactionStatus() : string