“慢生活”不是懒惰,放慢速度不是拖延时间,而是让我们在生活中寻找到平衡。网站首页程序人生
workerman调试-网络抓包
发布时间:2021-12-12 17:15:39作者:雪饮
![[!--pagekey--]](/d/file/manshenghuo/chengxurensheng/15d5478f2a8fa84113a84228946c8626.png)
现假定有这样一个简单的服务端程序:<?php
use Workerman\Worker;
use Workerman\Connection\TcpConnection;
require_once __DIR__ . '/vendor/autoload.php';
$worker = n
workerman实现http客户端及chunk服务端
发布时间:2021-12-12 14:40:51作者:雪饮
![[!--pagekey--]](/d/file/manshenghuo/chengxurensheng/02ccd71843180fce701f174fa9c3f5ea.png)
为了实现客户端我们需要在workerman源码基础上用composer新增下http客户端的子源码包。[root@localhost workerman]# /usr/local/php734/bin/php -c /usr/local/php734/lib
阅读全文>>workerman的http服务-基本调试 - 查看运行状态
发布时间:2021-12-12 12:40:33作者:雪饮
![[!--pagekey--]](/e/data/images/notimg.gif)
查看运行状态运行 如:[root@localhost workerman]# /usr/local/php734/bin/php -c /usr/local/php734/lib/php/php.ini start.php status可以查看到WorkerMan的运行状态,类似
阅读全文>>workerman的http服务-基本调试
发布时间:2021-12-11 23:55:23作者:雪饮
![[!--pagekey--]](/e/data/images/notimg.gif)
基本调试WorkerMan有两种运行模式,调试模式以及daemon运行模式 运行 php start.php start 进入调试模式,这时代码中的echo、var_dump、var_export等函数打印会在终端显示。注
阅读全文>>workerman的http服务-SSE(推送服务,服务端主推)
发布时间:2021-12-10 23:46:12作者:雪饮
![[!--pagekey--]](/d/file/manshenghuo/chengxurensheng/98b21d74bd6bd4892363c70b73b9298e.png)
SSE此特性需要workerman>=4.0.0SSE也就是Server-sent Events,是一种服务端推送技术。它的本质是客户端发送一个携带Accept: text/event-stream 头的http请求后,连接不关闭,服
阅读全文>>