class Factory implements LoggerAwareInterface
Factory provides method to create locks.
LoggerAwareTrait |
__construct(StoreInterface $store) | ||
Lock | createLock(string $resource, float|null $ttl = 300.0, bool $autoRelease = true) Creates a lock for the given resource. |
StoreInterface | $store |
Creates a lock for the given resource.
string | $resource | The resource to lock |
float|null | $ttl | Maximum expected lock duration in seconds |
bool | $autoRelease | Whether to automatically release the lock or not when the lock instance is destroyed |
Lock |
© 2004–2017 Fabien Potencier
Licensed under the MIT License.
https://api.symfony.com/4.1/Symfony/Component/Lock/Factory.html