public function acquire_key($key, &$auto_unlocker) { $t = microtime(true); while (!$this->lock_key($key, $auto_unlocker)) { if (microtime(true) - $t > $this->max_wait_unlock) { return false; } } return true; }