Open sandboxFocus

Interface ILockingStrategy

Provides instances of named locks for synchronizing concurrent executions of cached methods.

Namespace: Metalama.Patterns.Caching.Locking
Assembly: Metalama.Patterns.Caching.Backend.dll
Syntax
public interface ILockingStrategy
Remarks

Two built-in implementations are provided:

The locking strategy is configured per caching profile through the CachingProfile.LockingStrategy property.

Methods

Name Description
GetLock(string)

Gets a handle to a named lock. This method must return immediately. Waiting, if any, must be done in the Acquire(TimeSpan, CancellationToken) method.

Extension Methods

See Also