Skip to content

Commit 61a4c42

Browse files
committed
SetTransactionAdvisoryLockAsync
1 parent 3dd4d92 commit 61a4c42

1 file changed

Lines changed: 8 additions & 2 deletions

File tree

NetChris.Core/Patterns/IApplicationAdvisoryLockService.cs

Lines changed: 8 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -14,9 +14,15 @@ namespace NetChris.Core.Patterns;
1414
public interface IApplicationAdvisoryLockService
1515
{
1616
/// <summary>
17-
/// Sets an advisory lock asynchronously for the specified value on the transaction
17+
/// Sets a transaction-level advisory lock for specified value
1818
/// </summary>
19+
/// <remarks>
20+
/// As the name implies, the lock is help for the duration of a transaction. There is no prescription where that
21+
/// transaction lives or how it is managed. It is up to the application to ensure that the implementation uses some
22+
/// mechanism (usually a database transaction), to ensure that the transaction is resolved (committed or rolled back)
23+
/// in a timely manner.
24+
/// </remarks>
1925
/// <param name="lockId">The advisory lock ID</param>
2026
/// <param name="cancellationToken">The cancellation token used when first acquiring the lock</param>
21-
Task SetAdvisoryLockAsync(int lockId, CancellationToken cancellationToken);
27+
Task SetTransactionAdvisoryLockAsync(int lockId, CancellationToken cancellationToken);
2228
}

0 commit comments

Comments
 (0)