Skip to content

About

based on lua script redis lock for webman plugin

Topics

Resources

Stars

6 stars

Watchers

1 watching

Forks

Latest commit

 

History

7 Commits

Folders and files

NameName
Last commit message
Last commit date
 
 
 
 
 
 
 
 
 
 

Repository files navigation

based on lua script redis lock for webman plugin

Latest Stable Version Total Downloads Latest Unstable Version License PHP Version Require

安装

composer require tinywan/webman-lock

使用

// 锁名称
$lockName = md5((string) time());
// 锁标识
$lockId = \Tinywan\Lock\RedisLock::acquire($lockName);
if (!$lockId) {
    return '未获得锁标识,请稍后再试';
}

// 业务处理

// 释放锁
\Tinywan\Lock\RedisLock::release($lockName, $lockId);

About

based on lua script redis lock for webman plugin

Topics

Resources

Stars

6 stars

Watchers

1 watching

Forks

Releases

Packages

Used by

Contributors

Languages