Skip to content
This repository has been archived by the owner on Sep 1, 2020. It is now read-only.

Latest commit

 

History

History
12 lines (8 loc) · 297 Bytes

2.2.1 - Server::$setting.md

File metadata and controls

12 lines (8 loc) · 297 Bytes

Server::$setting

Server::set()函数所设置的参数会保存到Server->$setting属性上。在回调函数中可以访问运行参数的值。

示例:

$serv = new Swoole\Server('127.0.0.1', 9501);
$serv->set(array('worker_num' => 4));

echo $serv->setting['worker_num'];