请问swoole的内存锁怎么用?
网友回复
$lock = new swoole_lock(SWOOLE_MUTEX); echo "[Master]create lock\n"; $lock->lock(); if(pcntl_fork() > 0) { sleep(1); $lock->unlock(); } el...
点击查看剩余70%
请问swoole的内存锁怎么用?
网友回复
$lock = new swoole_lock(SWOOLE_MUTEX); echo "[Master]create lock\n"; $lock->lock(); if(pcntl_fork() > 0) { sleep(1); $lock->unlock(); } el...
点击查看剩余70%