PHPackages                             captainbi/hyperf - 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. [Framework](/categories/framework)
4. /
5. captainbi/hyperf

ActiveLibrary[Framework](/categories/framework)

captainbi/hyperf
================

v2.0(3y ago)02.0k1MITPHPPHP &gt;=7.3

Since Jul 25Pushed 2mo ago1 watchersCompare

[ Source](https://github.com/scwdl110/hyperf_common)[ Packagist](https://packagist.org/packages/captainbi/hyperf)[ RSS](/packages/captainbi-hyperf/feed)WikiDiscussions master Synced 1w ago

READMEChangelogDependencies (12)Versions (4)Used By (0)

CaptainBI Hyperf 公共组件库
======================

[](#captainbi-hyperf-公共组件库)

安装
--

[](#安装)

```
composer require captainbi/hyperf:dev-master
```

发布组件
----

[](#发布组件)

```
php bin/hyperf.php vendor:publish captainbi/hyperf
```

Apollo 组件使用说明
-------------

[](#apollo-组件使用说明)

修改 apollo 配置，通过 `.env` 文件进行配置

```
## 配置文件路径 config/autoload/apollo.php

# 是否开启 apollo
APOLLO_ENABLE=true
# apollo 服务器地址
APOLLO_SERVER=http://127.0.0.1:8080
# apollo appid
APOLLO_APPID=abcdefghijklmn
# 要拉取的 apollo 配置 namespaces，多个使用 英文逗号 , 分隔
APOLLO_NAMESPACES="application,database.json,redis.yml"
```

apollo 组件基于 hyperf 官方的 [config-apollo](https://github.com/hyperf/config-apollo/tree/2.1) 组件进行修改，只支持 2.1 版本，2.2 版本推荐使用 [config-center](https://hyperf.wiki/2.2/#/zh-cn/config-center)

具体区别与使用方式见 内网Wiki [hyperf 2.1 apollo 配置及使用说明](http://wiki.captainbi.com/pages/viewpage.action?pageId=3704233)

重启服务 组件使用说明
-----------

[](#重启服务-组件使用说明)

修改 重启服务 配置，通过 `.env` 文件进行配置

```
## 配置文件路径 config/autoload/restart_console.php

# 热重启启动脚本路径，默认在 bin/restart.php
RESTART_CONSOLE_SCRIPT=
# 热重启等待进程退出超时时间，单位 秒，可选值 3-60，默认 60秒
RESTART_CONSOLE_TIMEOUT=60

# 热重启失败发送警报的钉钉机器人 access token
RESTART_CONSOLE_DD_TOKEN=
# 热重启失败发送警报的钉钉机器人 api secret，安全设置 中使用 '加签' 模式的话，此配置不能为空
RESTART_CONSOLE_DD_SECRET=
# 热重启失败发送警报的钉钉机器人 消息，可使用的占位符见 config/autoload/restart_console.php 说明，可为空
RESTART_CONSOLE_DD_MESSAGE=
```

钉钉机器人详细说明见 [自定义机器人接入](https://developers.dingtalk.com/document/robots/custom-robot-access)

###  Health Score

35

—

LowBetter than 80% of packages

Maintenance58

Moderate activity, may be stable

Popularity16

Limited adoption so far

Community15

Small or concentrated contributor base

Maturity44

Maturing project, gaining track record

 Bus Factor1

Top contributor holds 71.1% 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 ~0 days

Total

2

Last Release

1394d ago

Major Versions

v1.0 → v2.02022-07-25

### Community

Maintainers

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

---

Top Contributors

[![ahendaxia](https://avatars.githubusercontent.com/u/29669634?v=4)](https://github.com/ahendaxia "ahendaxia (204 commits)")[![consatan](https://avatars.githubusercontent.com/u/1174105?v=4)](https://github.com/consatan "consatan (23 commits)")[![sam-vip](https://avatars.githubusercontent.com/u/10162137?v=4)](https://github.com/sam-vip "sam-vip (23 commits)")[![Jmiy](https://avatars.githubusercontent.com/u/72489604?v=4)](https://github.com/Jmiy "Jmiy (21 commits)")[![dly209](https://avatars.githubusercontent.com/u/24241459?v=4)](https://github.com/dly209 "dly209 (12 commits)")[![scwdl110](https://avatars.githubusercontent.com/u/30472008?v=4)](https://github.com/scwdl110 "scwdl110 (3 commits)")[![Quicklast555](https://avatars.githubusercontent.com/u/107230642?v=4)](https://github.com/Quicklast555 "Quicklast555 (1 commits)")

### Embed Badge

![Health badge](/badges/captainbi-hyperf/health.svg)

```
[![Health](https://phpackages.com/badges/captainbi-hyperf/health.svg)](https://phpackages.com/packages/captainbi-hyperf)
```

###  Alternatives

[laravel/framework

The Laravel Framework.

34.6k509.9M17.0k](/packages/laravel-framework)[cakephp/cakephp

The CakePHP framework

8.8k18.5M1.6k](/packages/cakephp-cakephp)[shopware/platform

The Shopware e-commerce core

3.3k1.5M3](/packages/shopware-platform)[magento/community-edition

Magento 2 (Open Source)

12.1k52.1k10](/packages/magento-community-edition)[flow-php/flow

PHP ETL - Extract Transform Load - Data processing framework

81733.7k](/packages/flow-php-flow)[nutgram/nutgram

The Telegram bot library that doesn't drive you nuts

714214.9k8](/packages/nutgram-nutgram)

PHPackages © 2026

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