/** * Transaction interface representing an active transaction */ export type ITransaction = { /** * Unique transaction ID */ readonly id: string; /** * Commit the transaction */ commit(): Promise; /** * Rollback the transaction */ rollback(): Promise; /** * Check if transaction is still active */ isActive(): boolean; }; /** * Compensation function for rollback * Undoes a specific operation */ export type CompensationFn = () => Promise; /** * Transaction Manager * Manages transaction lifecycle and compensation tracking */ export declare class TransactionManager { private readonly logger; /** * Begin a new transaction */ begin(): Promise; /** * Helper: Execute operation with automatic rollback on failure */ executeWithRollback(operation: (transaction: ITransaction) => Promise, compensation?: CompensationFn): Promise; } //# sourceMappingURL=transaction.manager.d.ts.map