Transactor

zoobie.Transactor
See theTransactor companion object
sealed abstract class Transactor

Attributes

Companion:
object
Source:
Transactor.scala
Graph
Supertypes
class Object
trait Matchable
class Any
Self type

Members list

Concise view

Value members

Abstract methods

def connection: ZIO[Scope, Connection, Connection]

Attributes

Source:
Transactor.scala
def interpreter: Interpreter[Task]

Attributes

Source:
Transactor.scala
def strategy: Strategy

Attributes

Source:
Transactor.scala

Concrete methods

def run[A](io: ConnectionIO[A])(implicit trace: Trace): ZIO[Any, DatabaseError, A]

Execute the given ConnectionIO on a connection using the strategy.

Execute the given ConnectionIO on a connection using the strategy.

Attributes

Source:
Transactor.scala
def stream[A](s: Stream[ConnectionIO, A])(implicit trace: Trace): ZStream[Any, DatabaseError, A]

Executes each ConnectionIO in the stream individually on a connection using the strategy.

Executes each ConnectionIO in the stream individually on a connection using the strategy.

Attributes

Source:
Transactor.scala
def streamSingleConnection[A](s: Stream[ConnectionIO, A])(implicit trace: Trace): ZStream[Any, DatabaseError, A]

Executes each ConnectionIO in the stream on a single connection using the strategy.

Executes each ConnectionIO in the stream on a single connection using the strategy.

Use with care with a strategy that is transactional as the transaction will be open until the stream completes. This means if the connection came from a pool it will not be returned until the stream completes.

Attributes

Source:
Transactor.scala
def translate(c: Connection): FunctionK[ConnectionIO, Task]

Attributes

Source:
Transactor.scala
def withStrategy(s: Strategy): Transactor

Attributes

Source:
Transactor.scala