Configuration for the lock behaviour.
A factory that creates named locks. Each lock is keyed by the file key to ensure concurrent operations on the same file are serialised while operations on different files can proceed in parallel.
OptionalonlyMethods?: WithFileStorageLockMethods[]The subset of methods to protect with a lock.
When omitted, all methods except removeByPrefix are protected by default.
A middleware plugin that wraps an ISignedFileStorageAdapter.
Creates a plugin that acquires a distributed lock before executing any operation on a file-storage adapter.
This plugin wraps all methods (reads, writes, copy/move, removal, and URL generation) with a lock acquired via
ILockFactory. The lock key is derived from the file key (or source key forcopy/move), ensuring that concurrent operations on the same file are serialised while operations on different files can proceed in parallel.By default all methods are protected. Use
onlyMethodsto restrict which operations are locked.