easyPHP-Swoole 专为API而生,是一款常驻内存化的PHP开发框架

网友投稿 1380 2022-11-03

easyPHP-Swoole 专为API而生,是一款常驻内存化的PHP开发框架

easyPHP-Swoole 专为API而生,是一款常驻内存化的PHP开发框架

EasySwoole - A High Performance Swoole Framework

EasySwoole is a distributed, persistent memory PHP framework based on the Swoole extension. It was created specifically for APIs to get rid of the performance penalties associated with process calls and file loading. EasySwoole highly encapsulates the Swoole Server and still maintains the original features of the Swoole server, supports simultaneous monitoring of HTTP, custom TCP, and UDP protocols, allowing developers to write multi-process, asynchronous, and highly available applications with minimal learning cost and effort.

Base on Swoole extensionBuilt-in HTTP, TCP, WebSocket,Udp Coroutine ServerGlobal dependency injection containerPSR-7 based HTTP message implementationHTTP,TCP, WebSocket, Udp middleware supportScalable high performance RPCDatabase ORMMysql, Redis, RPC, HTTP Coroutine ClientsCoroutine and asynchronous task deliveryCustom user processesRESTful supportedHigh performance routerFast and flexible parameter validatorPowerful log componentUniversal connection poolsRemote Console supportCrontab Rule Timer support

Doc

DocGit For Doc

ab Test

response()->write('Hello World'); }}

1 Core 1G RAM

command : ab -c 100 -n 10000 http://192.168.0.11:9501/

Server Software: EasySwooleServer Hostname: 192.168.0.11Server Port: 9501Document Path: /Document Length: 21 bytesConcurrency Level: 100Time taken for tests: 0.652 secondsComplete requests: 10000Failed requests: 0Write errors: 0Total transferred: 1690000 bytesHTML transferred: 210000 bytesRequests per second: 15325.16 [#/sec] (mean)Time per request: 9.685 [ms] (mean)Time per request: 0.097 [ms] (mean, across all concurrent requests)Transfer rate: 2592.05 [Kbytes/sec] received

8 Core 16G RAM

command : ab -c 100 -n 10000 http://192.168.0.4:9501/

Server Software: EasySwooleServer Hostname: 192.168.0.4Server Port: 9501Document Path: /Document Length: 21 bytesConcurrency Level: 100Time taken for tests: 0.746 secondsComplete requests: 10000Failed requests: 0Write errors: 0Total transferred: 1690000 bytesHTML transferred: 210000 bytesRequests per second: 66935.97 [#/sec] (mean)Time per request: 1.149 [ms] (mean)Time per request: 0.015 [ms] (mean, across all concurrent requests)Transfer rate: 2265.40 [Kbytes/sec] received

Quick Start

composer require easyswoole/easyswoole=3.xphp vendor/bin/easyswoole installphp easyswoole start

Unit Test

after install easyswoole,run:

php easyswoole phpunit ./vendor/easyswoole/easyswoole/tests

docker

Get Docker Image

docker pull easyswoole/easyswoole3

Run

docker run -ti -p 9501:9501 easyswoole/easyswoole3

WorkerDir: /easyswooleRun Easyswoole : php easyswoole start

Others

Git For Demo QQ交流群VIP群 579434607 (本群需要付费599元)EasySwoole官方一群 633921431(已满)EasySwoole官方二群 709134628 商业支持:QQ 291323003EMAIL admin@fosuss.com

版权声明:本文内容由网络用户投稿,版权归原作者所有,本站不拥有其著作权,亦不承担相应法律责任。如果您发现本站中有涉嫌抄袭或描述失实的内容,请联系我们jiasou666@gmail.com 处理,核实后本网站将在24小时内删除侵权内容。

上一篇:基本算法练习——上台阶
下一篇:SpringBoot项目拦截器获取Post方法的请求body实现
相关文章

 发表评论

暂时没有评论,来抢沙发吧~