Configuring TransactionContext adapters
KyselyTransactionAdapter
KyselyTransactionAdapter
Implementing your custom ITransactionAdapter
The ProxyTransactionContextResolver class provides an ITransactionContextResolver whose underlying resolver is resolved from a DI container.
Transaction-context middlewares wrap functions to run them within a transaction or defer them until a transaction commits. They let you apply transaction behavior without adding it to the function implementation.
The eridu-tech/transaction-context component lets you run code inside a database transaction and access the client that belongs to the current transaction scope, without passing it around manually.
The TransactionContextResolver creates a transaction context for each configured adapter. Use it to run work with a default transaction adapter or select a specific adapter at runtime.