FulcrumFS FulcrumFS
FulcrumFS FulcrumFS
DocFX + Singulink = ♥

Search Results for

    Event TransactionCompletionFailed

    Occurs when a transaction-completion step (commit or rollback) fails. The handler receives a RepoTransactionCompletionFailureInfo carrying the operation that failed and the underlying exception, and can be used to log errors or perform custom error handling.

    Implements
    TransactionCompletionFailed
    Namespace: FulcrumFS
    Assembly: FulcrumFS.Local.dll
    Syntax
    public event RepoTransactionCompletionFailedHandler? TransactionCompletionFailed
    Returns
    Type Description
    RepoTransactionCompletionFailedHandler Occurs when a transaction-completion step (commit or rollback) fails. The handler receives a carrying the operation that failed and the underlying exception, and can be used to log errors or perform custom error handling.
    Remarks

    This event fires only for failures of the final commit or rollback step itself, not for in-flight exceptions raised while operating on the transaction (validation errors, processor failures, etc., which surface directly to the calling code).

    If multiple errors occurred during the completion step, Exception will be an AggregateException.

    Exceptions are not thrown automatically for completion-step failures since the affected files (added during commit or scheduled for deletion during rollback) remain accessible afterwards; they are merely left in an indeterminate state pending repair by the next cleaner pass. The handler can throw an exception if throwing behavior is desired.

    The event is raised once the commit or rollback has done all it can, and the handlers are awaited in turn. An exception that a handler throws therefore propagates from the commit or rollback call after the fact and undoes nothing, and it keeps the handlers subscribed after it from being called. A caller that sees one from CommitAsync(CancellationToken) or CommitAsync(CancellationToken) must not conclude that the transaction was not committed or was rolled back: every file of it is committed or left indeterminate, stays accessible, and is not rolled back when the transaction is disposed.

    © Singulink. All rights reserved.