PHPackages                             workerman/gateway-worker - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. [HTTP &amp; Networking](/categories/http)
4. /
5. workerman/gateway-worker

ActiveLibrary[HTTP &amp; Networking](/categories/http)

workerman/gateway-worker
========================

v4.0.1(10mo ago)1.0k643.4k—0.6%294[26 issues](https://github.com/walkor/GatewayWorker/issues)20MITPHPPHP &gt;=7.2

Since Nov 13Pushed 10mo ago47 watchersCompare

[ Source](https://github.com/walkor/GatewayWorker)[ Packagist](https://packagist.org/packages/workerman/gateway-worker)[ Docs](http://www.workerman.net)[ Fund](https://opencollective.com/walkor)[ Patreon](https://www.patreon.com/walkor)[ RSS](/packages/workerman-gateway-worker/feed)WikiDiscussions master Synced 1mo ago

READMEChangelog (10)Dependencies (1)Versions (42)Used By (20)

GatewayWorker
=============

[](#gatewayworker)

GatewayWorker基于[Workerman](https://github.com/walkor/Workerman)开发的一个项目框架，用于快速开发长连接应用，例如app推送服务端、即时IM服务端、游戏服务端、物联网、智能家居等等。

GatewayWorker使用经典的Gateway和Worker进程模型。Gateway进程负责维持客户端连接，并转发客户端的数据给Worker进程处理；Worker进程负责处理实际的业务逻辑，并将结果推送给对应的客户端。Gateway服务和Worker服务可以分开部署在不同的服务器上，实现分布式集群。

GatewayWorker提供非常方便的API，可以全局广播数据、可以向某个群体广播数据、也可以向某个特定客户端推送数据。配合Workerman的定时器，也可以定时推送数据。

快速开始
====

[](#快速开始)

开发者可以从一个简单的demo开始(demo中包含了GatewayWorker内核，以及start\_gateway.php start\_business.php等启动入口文件)
[点击这里下载demo](http://www.workerman.net/download/GatewayWorker.zip)。
demo说明见源码readme。

手册
==

[](#手册)

安装内核
====

[](#安装内核)

只安装GatewayWorker内核文件（不包含start\_gateway.php start\_businessworker.php等启动入口文件）

```
composer require workerman/gateway-worker

```

使用GatewayWorker开发的项目
====================

[](#使用gatewayworker开发的项目)

[tadpole](http://kedou.workerman.net/)
--------------------------------------

[](#tadpole)

[Source code](https://github.com/walkor/workerman-todpole)
[![workerman todpole](https://camo.githubusercontent.com/de65f69541236da9275b319561d7c11a65f4d941ffc7eb5814f164cc3f8737e7/687474703a2f2f7777772e776f726b65726d616e2e6e65742f696d672f776f726b65726d616e2d746f64706f6c652e706e67)](https://camo.githubusercontent.com/de65f69541236da9275b319561d7c11a65f4d941ffc7eb5814f164cc3f8737e7/687474703a2f2f7777772e776f726b65726d616e2e6e65742f696d672f776f726b65726d616e2d746f64706f6c652e706e67)

[chat room](http://chat.workerman.net/)
---------------------------------------

[](#chat-room)

[Source code](https://github.com/walkor/workerman-chat)
[![workerman-chat](https://camo.githubusercontent.com/538edc71fe88995245709761d9627297dabe4ce11f1a88efb550700f973266c7/687474703a2f2f7777772e776f726b65726d616e2e6e65742f696d672f776f726b65726d616e2d636861742e706e67)](https://camo.githubusercontent.com/538edc71fe88995245709761d9627297dabe4ce11f1a88efb550700f973266c7/687474703a2f2f7777772e776f726b65726d616e2e6e65742f696d672f776f726b65726d616e2d636861742e706e67)

###  Health Score

60

—

FairBetter than 99% of packages

Maintenance52

Moderate activity, may be stable

Popularity63

Solid adoption and visibility

Community48

Growing community involvement

Maturity70

Established project with proven stability

 Bus Factor1

Top contributor holds 88.6% of commits — single point of failure

How is this calculated?**Maintenance (25%)** — Last commit recency, latest release date, and issue-to-star ratio. Uses a 2-year decay window.

**Popularity (30%)** — Total and monthly downloads, GitHub stars, and forks. Logarithmic scaling prevents top-heavy scores.

**Community (15%)** — Contributors, dependents, forks, watchers, and maintainers. Measures real ecosystem engagement.

**Maturity (30%)** — Project age, version count, PHP version support, and release stability.

###  Release Activity

Cadence

Every ~80 days

Recently: every ~123 days

Total

40

Last Release

325d ago

Major Versions

v3.1.18 → v4.0.02025-02-15

PHP version history (2 changes)v3.0.28PHP &gt;=7.0

v4.0.0PHP &gt;=7.2

### Community

Maintainers

![](https://www.gravatar.com/avatar/c8bc354ebf6983ed6334dd25ad0c1003b0034bcd148111d2d7ef463171f4dcba?d=identicon)[workerman](/maintainers/workerman)

---

Top Contributors

[![walkor](https://avatars.githubusercontent.com/u/6073368?v=4)](https://github.com/walkor "walkor (256 commits)")[![agui2200](https://avatars.githubusercontent.com/u/6271220?v=4)](https://github.com/agui2200 "agui2200 (5 commits)")[![twomiao](https://avatars.githubusercontent.com/u/35003997?v=4)](https://github.com/twomiao "twomiao (4 commits)")[![xuanyanwow](https://avatars.githubusercontent.com/u/28777109?v=4)](https://github.com/xuanyanwow "xuanyanwow (3 commits)")[![detain](https://avatars.githubusercontent.com/u/1364504?v=4)](https://github.com/detain "detain (3 commits)")[![captainstdin](https://avatars.githubusercontent.com/u/56504552?v=4)](https://github.com/captainstdin "captainstdin (3 commits)")[![mouyong](https://avatars.githubusercontent.com/u/10336437?v=4)](https://github.com/mouyong "mouyong (3 commits)")[![Yurunsoft](https://avatars.githubusercontent.com/u/20104656?v=4)](https://github.com/Yurunsoft "Yurunsoft (2 commits)")[![linjialiang](https://avatars.githubusercontent.com/u/8848263?v=4)](https://github.com/linjialiang "linjialiang (1 commits)")[![pz9042](https://avatars.githubusercontent.com/u/5012019?v=4)](https://github.com/pz9042 "pz9042 (1 commits)")[![ttlxihuan](https://avatars.githubusercontent.com/u/15153371?v=4)](https://github.com/ttlxihuan "ttlxihuan (1 commits)")[![keppelcao](https://avatars.githubusercontent.com/u/1754641?v=4)](https://github.com/keppelcao "keppelcao (1 commits)")[![huangdijia](https://avatars.githubusercontent.com/u/8337659?v=4)](https://github.com/huangdijia "huangdijia (1 commits)")[![wenzhihong2003](https://avatars.githubusercontent.com/u/486365?v=4)](https://github.com/wenzhihong2003 "wenzhihong2003 (1 commits)")[![woann](https://avatars.githubusercontent.com/u/25681022?v=4)](https://github.com/woann "woann (1 commits)")[![xiasf](https://avatars.githubusercontent.com/u/17535757?v=4)](https://github.com/xiasf "xiasf (1 commits)")[![hlxabcd](https://avatars.githubusercontent.com/u/2756343?v=4)](https://github.com/hlxabcd "hlxabcd (1 commits)")[![cxlblm](https://avatars.githubusercontent.com/u/17900096?v=4)](https://github.com/cxlblm "cxlblm (1 commits)")

---

Tags

distributed-systemsrealtime-messagingwebsocketworkermancommunicationdistributed

### Embed Badge

![Health badge](/badges/workerman-gateway-worker/health.svg)

```
[![Health](https://phpackages.com/badges/workerman-gateway-worker/health.svg)](https://phpackages.com/packages/workerman-gateway-worker)
```

###  Alternatives

[workerman/mqtt

22450.3k12](/packages/workerman-mqtt)[linwj/binance

Binance API Like the official document interface, Support for arbitrary extension.

11617.7k1](/packages/linwj-binance)[workerman/http-client

5572.7k17](/packages/workerman-http-client)[webman/openai

OpenAI client for webman or workerman

663.7k](/packages/webman-openai)[linwj/okex

Okex API Like the official document interface, Support for arbitrary extension.

5612.4k1](/packages/linwj-okex)[workerman/gateway-worker-for-win

1711.1k2](/packages/workerman-gateway-worker-for-win)

PHPackages © 2026

[Directory](/)[Categories](/categories)[Trending](/trending)[Changelog](/changelog)[Analyze](/analyze)
