Core Concepts — ITransactionManager, Options & Savepoints
EricksonLopez.Transaction separates lifecycle coordination (ITransactionManager) from active unit-of-work handles (ITransaction) and safe command execution (ITransactionContext).
ITransactionManager, ITransaction & ITransactionContext
Section titled “ITransactionManager, ITransaction & ITransactionContext”ITransactionManager: ExposesCurrentContext,BeginAsync(TransactionOptions? = null, CancellationToken = default) -> Task<ITransaction>, andExecuteAsync(...).ITransaction : IAsyncDisposable: ExposesTransactionId,Context,State,CommitAsync,RollbackAsync, andCreateSavepointAsync(string name, CancellationToken = default).TransactionResultExtensions.ExecuteResultAsync: Commits automatically onResult.IsSuccessand rolls back onResult.IsFailure.
Defaults IsolationLevel.ReadCommitted, NestedBehavior = NestedTransactionBehavior.UseSavepoint (JoinExisting, RequireNew, Suppress also available), DeferAcquisition = false, CommitOnFailure = false, and SanitizeTelemetryMetadata, alongside static presets Default, Serializable, ReadOnlyMode, Deferred, Autonomous, and WithTimeout(TimeSpan). (Note: OwnsConnection = true is a v3.0.0 local addition.)