Documentation

TypeDB.Async

Async transactions #

Driver.run returns a Std.Async.EAsync TypeDBError α. The driver's calls block their thread, so each transaction runs on a thread of its own (Task.Priority.dedicated) and never occupies one of the task pool's workers. Combine transactions with Std.Async combinators such as EAsync.concurrently, EAsync.race and EAsync.concurrentlyAll, and wait for the result with EAsync.wait or EAsync.block.

Runs a blocking TypeDB action on a dedicated thread, as an EAsync computation.

Equations
Instances For
    def TypeDB.Driver.run {α : Type} (d : Driver) (db : String) (mode : TxMode) (body : Tx mode α) (retry : RetryPolicy := RetryPolicy.never) (opts : TxOptions := { }) :

    Runs a transaction on a dedicated thread. Same commit, rollback and retry semantics as runSync.

    Equations
    Instances For