xielei/project

SwooleWorker 脚手架,快速搭建开发结构~

维护者

详细信息

github.com/xielei/project

源代码

问题

安装次数: 156

依赖者: 0

建议者: 0

安全性: 0

星标: 2

关注者: 1

分支: 2

开放问题: 1

类型:项目

1.0.3 2021-08-26 12:21 UTC

This package is auto-updated.

Last update: 2024-09-20 13:49:06 UTC


README

这是一个【SwooleWorker】脚手架

安装方法

方法1(推荐):

composer create-project xielei/project

方法2:

直接下载本项目,然后执行

composer install

启动

[root@VM-0-17-centos project]# php app/register/start.php start -d
the service is running with daemonize
[root@VM-0-17-centos project]# php app/worker/start.php start -d
the service is running with daemonize
[root@VM-0-17-centos project]# php app/gateway/start.php start -d
the service is running with daemonize
[root@VM-0-17-centos project]# 

体验测试

窗口1:

[root@VM-0-17-centos project]# telnet 127.0.0.1 8000
Trying 127.0.0.1...
Connected to 127.0.0.1.
Escape character is '^]'.
7f000001239400000001 connect~
7f000001239400000002 connect~
7f000001239400000002 say 你好
嗯嗯 我很好
7f000001239400000001 say 嗯嗯 我很好
7f000001239400000002 say 拜拜
7f000001239400000002 exit~

窗口2

[root@VM-0-17-centos project]# telnet 127.0.0.1 8000
Trying 127.0.0.1...
Connected to 127.0.0.1.
Escape character is '^]'.
7f000001239400000002 connect~
你好
7f000001239400000002 say 你好
7f000001239400000001 say 嗯嗯 我很好
拜拜
7f000001239400000002 say 拜拜
^]quit

telnet> quit
Connection closed.
[root@VM-0-17-centos project]#