# 代码以及语法:
~~~
<?php
// 实例化一个tcp出来
$server =new Swoole\Server('0.0.0.0',8887,SWOOLE_PROCESS,SWOOLE_SOCK_TCP);
$setting=[
'worker_num'=>6 //启动6个进程
];
$server->set($setting);
//回调函数必须设置
$server->on('receive',function (){});
$server->start(); //启动命令
~~~