承接 gregorip02/servel 相关项目开发

从需求分析到上线部署,全程专人跟进,保证项目质量与交付效率

邮箱:yvsm@zunyunkeji.com | QQ:316430983 | 微信:yvsm316

gregorip02/servel

Composer 安装命令:

composer require gregorip02/servel

包简介

Workerman server adapter for Laravel

README 文档

README

Latest Stable Version Total Downloads License

WIP: This package provides a tcp entry point for your Laravel application, powered by the high-performance Workerman server.

Install

# Install the package
composer require gregorip02/servel

# Publish the configuration package
php artisan vendor:publish --tag=servel-config

Usage

php artisan servel start
php artisan servel stop
php artisan servel connections
php artisan servel restart
php artisan servel reload
php artisan servel status

Benchmarking

DO Droplet - CPU Dedicated
- 8GB Memory
- 50GB SSD
- 8 VCPUs

Render the default welcome.blade.php view

wrk -t4 -c50 http://0.0.0.0/

Running 10s test @ http://0.0.0.0/
  4 threads and 50 connections
  Thread Stats   Avg      Stdev     Max   +/- Stdev
    Latency    27.16ms    5.74ms 124.65ms   92.53%
    Req/Sec    443.86     49.22   520.00     86.25%
  17687 requests in 10.01s, 312.24MB read
  Socket errors: connect 0, read 17687, write 0, timeout 0
Requests/sec:   1767.28
Transfer/sec:   31.20MB

A simple endpoint that responds pong

wrk -t4 -c50 http://0.0.0.0/ping

Running 10s test @ http://0.0.0.0/ping
  4 threads and 50 connections
  Thread Stats   Avg      Stdev     Max   +/- Stdev
    Latency    25.62ms    5.95ms  95.00ms   89.80%
    Req/Sec    469.97     56.74   585.00     77.25%
  18724 requests in 10.01s, 18.30MB read
  Socket errors: connect 0, read 18724, write 0, timeout 0
Requests/sec:   1871.13
Transfer/sec:   1.83MB

An endpoint that responds 100 users in JSON format from a SQLite database. I/O

wrk -t4 -c50 http://0.0.0.0/users

Running 10s test @ http://0.0.0.0/users
  4 threads and 50 connections
  Thread Stats   Avg      Stdev     Max   +/- Stdev
    Latency   288.79ms   28.25ms 397.73ms   94.93%
    Req/Sec   41.16      17.08   101.00     63.38%
  1638 requests in 10.01s, 33.76MB read
  Socket errors: connect 0, read 1638, write 0, timeout 0
Requests/sec:    163.63
Transfer/sec:    3.37MB

TODO

  • Add tests
  • Add support for run in "daemon" mode
  • Add support for websockets
  • Add support for restarts in development mode
  • Add command to restart the servers
  • Add command to stop the servers
  • Add support for publish configuration file
  • Add support for parameters, cookies, files, headers, etc.

统计信息

  • 总下载量: 32
  • 月度下载量: 0
  • 日度下载量: 0
  • 收藏数: 2
  • 点击次数: 0
  • 依赖项目数: 0
  • 推荐数: 0

GitHub 信息

  • Stars: 2
  • Watchers: 1
  • Forks: 0
  • 开发语言: PHP

其他信息

  • 授权协议: MIT
  • 更新时间: 2021-03-06

承接程序开发

PHP开发

VUE

Vue开发

前端开发

小程序开发

公众号开发

系统定制

数据库设计

云部署

网站建设

安全加固