Member Junction
    Preparing search index...

    Capability checks on a metadata provider, and the isolated unit of work built on them.

    Index

    Constructors

    Methods

    • Runs one unit of work (a record's write-back, a version-registry lock) on its own provider instance (CreateIndependentInstance, released afterwards), so no other statement on the shared provider lands in its transaction. When the caller is in a transaction on provider (another scope's transaction does not count), the unit joins it as a savepoint and the caller owns atomicity; a provider that is not a DatabaseProviderBase (a client provider) runs the unit on itself.

      Type Parameters

      • T

      Parameters

      • provider: IMetadataProvider

        the caller's provider

      • work: (unitProvider: IMetadataProvider) => Promise<T>

        the unit, given the provider every read, save and the transaction must use

      Returns Promise<T>