From 4fe5f4c185334af6e6612f6689315fb987b5e064 Mon Sep 17 00:00:00 2001 From: Yurun Date: Fri, 13 Oct 2023 12:46:16 +0800 Subject: [PATCH] =?UTF-8?q?3.0=EF=BC=8C=E5=90=AF=E5=8A=A8=EF=BC=81?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .github/workflows/mirror.yml | 2 +- .github/workflows/split-repository.yml | 2 +- README.md | 24 ++--- doc/README.md | 20 ++--- doc/annotations/annotation.md | 4 +- doc/base/new.md | 12 +-- doc/base/qa.md | 2 +- doc/components/access-control.md | 4 +- doc/components/cache/index.md | 2 +- doc/components/config/center.md | 6 +- doc/components/httpserver/aop.md | 2 +- doc/components/httpserver/controller.md | 4 +- doc/components/httpserver/cros.md | 2 +- doc/components/httpserver/jwt.md | 2 +- doc/components/httpserver/validation.md | 2 +- doc/components/influxdb.md | 2 +- doc/components/macro.md | 2 +- doc/components/meter/index.md | 6 +- doc/components/meter/influxdb.md | 6 +- doc/components/meter/prometheus.md | 2 +- doc/components/meter/tdengine.md | 2 +- doc/components/mq/amqp.md | 4 +- doc/components/mq/kafka.md | 2 +- doc/components/mq/redis.md | 2 +- doc/components/mq/redisStream.md | 2 +- doc/components/mqtt/server.md | 2 +- doc/components/orm/RDModel.md | 2 +- doc/components/orm/RDModel/definition.md | 4 +- doc/components/orm/index.md | 2 +- doc/components/orm/migration.md | 2 +- doc/components/rate-limit.md | 2 +- doc/components/rpc/grpc-proxy.md | 4 +- doc/components/rpc/grpc.md | 4 +- doc/components/rpc/hprose.md | 2 +- doc/components/serviceDiscovery/index.md | 2 +- doc/components/serviceRegistry/index.md | 2 +- doc/components/shared-memory.md | 2 +- doc/components/smarty.md | 2 +- doc/components/snowflake.md | 2 +- doc/components/swoole-tracker.md | 2 +- doc/components/tcpServer/controller.md | 2 +- doc/components/tracing/index.md | 6 +- doc/components/tracing/opentracing.md | 4 +- doc/components/udpServer/controller.md | 2 +- .../websocketServer/httpController.md | 2 +- doc/components/websocketServer/reconnect.md | 2 +- doc/components/websocketServer/session.md | 2 +- .../websocketServer/websocketController.md | 2 +- doc/core/container.md | 2 +- doc/dev/generate/swagger.md | 2 +- doc/mddoc.json | 2 +- doc/utils/Server.md | 2 +- doc/utils/Swoole.md | 2 +- mddoc/template/html/article.php | 5 +- src/Components/access-control/README.md | 4 +- src/Components/amqp/README.md | 4 +- src/Components/amqp/composer.json | 2 +- src/Components/amqp/dev/Dev.php | 8 +- src/Components/apidoc/README.md | 4 +- src/Components/grpc/README.md | 4 +- src/Components/grpc/composer.json | 2 +- src/Components/grpc/dev/Dev.php | 8 +- src/Components/hprose/README.md | 4 +- src/Components/hprose/composer.json | 4 +- src/Components/hprose/dev/Dev.php | 8 +- src/Components/jwt/README.md | 4 +- src/Components/kafka/README.md | 4 +- src/Components/kafka/composer.json | 2 +- src/Components/kafka/dev/Dev.php | 8 +- src/Components/macro/README.md | 4 +- src/Components/mqtt/README.md | 6 +- src/Components/mqtt/dev/Dev.php | 8 +- src/Components/pgsql/README.md | 2 +- src/Components/pgsql/dev/Dev.php | 8 +- .../phar/tests/project/composer.json | 12 +-- src/Components/phar/tests/run-tests.php | 2 +- src/Components/queue/README.md | 4 +- src/Components/queue/dev/Dev.php | 8 +- src/Components/rate-limit/README.md | 4 +- src/Components/rpc/README.md | 4 +- src/Components/rpc/composer.json | 2 +- src/Components/rpc/dev/Dev.php | 8 +- src/Components/shared-memory/README.md | 4 +- src/Components/shared-memory/composer.json | 2 +- src/Components/smarty/README.md | 4 +- src/Components/smarty/dev/Dev.php | 8 +- src/Components/snowflake/README.md | 4 +- src/Components/swoole-tracker/README.md | 4 +- src/Components/swoole-tracker/composer.json | 2 +- src/Components/swoole/dev/Dev.php | 8 +- src/Components/workerman-gateway/dev/Dev.php | 8 +- website/src/page/case.html | 2 +- website/src/page/course.html | 2 +- website/src/page/donate.html | 2 +- website/src/page/index.html | 90 +++++++++---------- 95 files changed, 238 insertions(+), 237 deletions(-) diff --git a/.github/workflows/mirror.yml b/.github/workflows/mirror.yml index 8cf97a7f62..78296f4d96 100644 --- a/.github/workflows/mirror.yml +++ b/.github/workflows/mirror.yml @@ -9,7 +9,7 @@ on: jobs: gitee: - if: github.repository == 'imiphp/imi' && (github.ref == 'refs/heads/2.1') + if: github.repository == 'imiphp/imi' && (github.ref == 'refs/heads/3.0') runs-on: ubuntu-20.04 steps: - uses: ahmadnassri/action-workflow-queue@v1 diff --git a/.github/workflows/split-repository.yml b/.github/workflows/split-repository.yml index 60bcd3de2f..65e62cef9b 100644 --- a/.github/workflows/split-repository.yml +++ b/.github/workflows/split-repository.yml @@ -3,7 +3,7 @@ name: split repository on: push: branches: - - "2.1" + - "3.0" release: types: [published] diff --git a/README.md b/README.md index 9046e4b83d..4ff7898924 100644 --- a/README.md +++ b/README.md @@ -2,18 +2,18 @@

- imi + imi

[![Latest Version](https://img.shields.io/packagist/v/imiphp/imi.svg)](https://packagist.org/packages/imiphp/imi) -![GitHub Workflow Status (branch)](https://img.shields.io/github/actions/workflow/status/imiphp/imi/ci.yml?branch=2.1) +![GitHub Workflow Status (branch)](https://img.shields.io/github/actions/workflow/status/imiphp/imi/ci.yml?branch=3.0) [![Php Version](https://img.shields.io/badge/php-%3E=7.4-brightgreen.svg)](https://secure.php.net/) [![Swoole Version](https://img.shields.io/badge/swoole-%3E=4.8.0-brightgreen.svg)](https://github.com/swoole/swoole-src) -[![imi Doc](https://img.shields.io/badge/docs-passing-green.svg)](https://doc.imiphp.com/v2.1/) +[![imi Doc](https://img.shields.io/badge/docs-passing-green.svg)](https://doc.imiphp.com/v3.0/) [![imi License](https://img.shields.io/badge/license-MulanPSL%202.0-brightgreen.svg)](https://github.com/imiphp/imi/blob/master/LICENSE) [![star](https://gitee.com/yurunsoft/IMI/badge/star.svg?theme=gvp)](https://gitee.com/yurunsoft/IMI/stargazers) -[![codecov](https://codecov.io/github/imiphp/imi/branch/2.1/graph/badge.svg?token=YrNRQgbRe2)](https://codecov.io/github/imiphp/imi) +[![codecov](https://codecov.io/github/imiphp/imi/branch/3.0/graph/badge.svg?token=YrNRQgbRe2)](https://codecov.io/github/imiphp/imi) ## 介绍 @@ -75,19 +75,19 @@ imi 框架进阶教程——五子棋游戏开发(免费7集全) +参与框架开发教程详见: diff --git a/doc/README.md b/doc/README.md index f49822020a..cd81f211e9 100644 --- a/doc/README.md +++ b/doc/README.md @@ -1,8 +1,8 @@ # 项目介绍 -![imi logo](https://cdn.jsdelivr.net/gh/imiphp/imi@2.1/res/logo.png) +![imi logo](https://cdn.jsdelivr.net/gh/imiphp/imi@3.0/res/logo.png) -[![Latest Version](https://img.shields.io/packagist/v/imiphp/imi.svg)](https://packagist.org/packages/imiphp/imi) ![GitHub Workflow Status (branch)](https://img.shields.io/github/actions/workflow/status/imiphp/imi/ci.yml?branch=2.1) [![Php Version](https://img.shields.io/badge/php-%3E=7.4-brightgreen.svg)](https://secure.php.net/) [![Swoole Version](https://img.shields.io/badge/swoole-%3E=4.8.0-brightgreen.svg)](https://github.com/swoole/swoole-src) [![imi Doc](https://img.shields.io/badge/docs-passing-green.svg)](/v2.1/) [![imi License](https://img.shields.io/badge/license-MulanPSL%202.0-brightgreen.svg)](https://github.com/imiphp/imi/blob/master/LICENSE) [![star](https://gitee.com/yurunsoft/IMI/badge/star.svg?theme=gvp)](https://gitee.com/yurunsoft/IMI/stargazers) +[![Latest Version](https://img.shields.io/packagist/v/imiphp/imi.svg)](https://packagist.org/packages/imiphp/imi) ![GitHub Workflow Status (branch)](https://img.shields.io/github/actions/workflow/status/imiphp/imi/ci.yml?branch=3.0) [![Php Version](https://img.shields.io/badge/php-%3E=7.4-brightgreen.svg)](https://secure.php.net/) [![Swoole Version](https://img.shields.io/badge/swoole-%3E=4.8.0-brightgreen.svg)](https://github.com/swoole/swoole-src) [![imi Doc](https://img.shields.io/badge/docs-passing-green.svg)](/v3.0/) [![imi License](https://img.shields.io/badge/license-MulanPSL%202.0-brightgreen.svg)](https://github.com/imiphp/imi/blob/master/LICENSE) [![star](https://gitee.com/yurunsoft/IMI/badge/star.svg?theme=gvp)](https://gitee.com/yurunsoft/IMI/stargazers) ## 介绍 @@ -64,19 +64,19 @@ imi 框架进阶教程——五子棋游戏开发(免费7集全)getDriver('nacos')->push($name, $value, [ ### Etcd -**安装:**`composer require imiphp/imi-etcd:~2.1.0` +**安装:**`composer require imiphp/imi-etcd:~3.0.0` **配置:** @@ -211,7 +211,7 @@ $configCenter->getDriver('etcd')->push($name, $value, $options); * 非 Swoole 用户请安装 [php-zookeeper]() 扩展。 -**安装:**`composer require imiphp/imi-zookeeper:~2.1.0` +**安装:**`composer require imiphp/imi-zookeeper:~3.0.0` **配置:** diff --git a/doc/components/httpserver/aop.md b/doc/components/httpserver/aop.md index a92cfb59cb..e0c4a4f19d 100644 --- a/doc/components/httpserver/aop.md +++ b/doc/components/httpserver/aop.md @@ -8,7 +8,7 @@ AOP(Aspect-Oriented Programming 面向切面编程)是一种在运行时, 动态地将一段代码片段(切面)切入到指定类、类的指定方法(切入点)等位置, 从而改变其原有的行为的编程思想。可以在不改变原有逻辑的基础上, 增加一些额外的功能,例如日志记录,性能统计,安全控制,事务处理,异常处理等。 -详细介绍请见:[链接](/v2.1/components/aop/index.html) +详细介绍请见:[链接](/v3.0/components/aop/index.html) ## Demo diff --git a/doc/components/httpserver/controller.md b/doc/components/httpserver/controller.md index a3a9479c32..6796b5c2dd 100644 --- a/doc/components/httpserver/controller.md +++ b/doc/components/httpserver/controller.md @@ -74,13 +74,13 @@ class Index extends HttpController ## 绑定请求参数到控制器方法参数 -详见:[链接](/v2.1/components/httpserver/request.html#%E7%BB%91%E5%AE%9A%E8%AF%B7%E6%B1%82%E5%8F%82%E6%95%B0%E5%88%B0%E6%8E%A7%E5%88%B6%E5%99%A8%E6%96%B9%E6%B3%95%E5%8F%82%E6%95%B0) +详见:[链接](/v3.0/components/httpserver/request.html#%E7%BB%91%E5%AE%9A%E8%AF%B7%E6%B1%82%E5%8F%82%E6%95%B0%E5%88%B0%E6%8E%A7%E5%88%B6%E5%99%A8%E6%96%B9%E6%B3%95%E5%8F%82%E6%95%B0) ## 属性 ### $server -详见:[链接](/v2.1/core/server.html) +详见:[链接](/v3.0/core/server.html) ### $request diff --git a/doc/components/httpserver/cros.md b/doc/components/httpserver/cros.md index 986daf6600..d64eb17bec 100644 --- a/doc/components/httpserver/cros.md +++ b/doc/components/httpserver/cros.md @@ -8,7 +8,7 @@ imi 框架内置了一个 `OptionsMiddleware` 中间件,用于解决使用 `ap 别名:`OptionsMiddleware` -中间件使用方法:[链接](/v2.1/components/httpserver/middleware.html) +中间件使用方法:[链接](/v3.0/components/httpserver/middleware.html) ## 参数设置 diff --git a/doc/components/httpserver/jwt.md b/doc/components/httpserver/jwt.md index 4203ad29c8..8b0fbbff36 100644 --- a/doc/components/httpserver/jwt.md +++ b/doc/components/httpserver/jwt.md @@ -21,7 +21,7 @@ imi v2 使用 2.0 版本 ```json { "require": { - "imiphp/imi-jwt": "~2.1.0" + "imiphp/imi-jwt": "~3.0.0" } } ``` diff --git a/doc/components/httpserver/validation.md b/doc/components/httpserver/validation.md index 15d2d415af..f2e476cb4a 100644 --- a/doc/components/httpserver/validation.md +++ b/doc/components/httpserver/validation.md @@ -2,7 +2,7 @@ [toc] -请先阅读 [验证器](/v2.1/components/validation/index.html) 章节,HTTP 验证器基于验证器扩展,基本使用方式相似。 +请先阅读 [验证器](/v3.0/components/validation/index.html) 章节,HTTP 验证器基于验证器扩展,基本使用方式相似。 ## @HttpValidation diff --git a/doc/components/influxdb.md b/doc/components/influxdb.md index d792d31224..03d8b6d375 100644 --- a/doc/components/influxdb.md +++ b/doc/components/influxdb.md @@ -12,7 +12,7 @@ imi-influxdb: ## 安装 -`composer require imiphp/imi-influxdb:~2.1.0` +`composer require imiphp/imi-influxdb:~3.0.0` ## 使用说明 diff --git a/doc/components/macro.md b/doc/components/macro.md index 8a670ac366..d08a3c87c0 100644 --- a/doc/components/macro.md +++ b/doc/components/macro.md @@ -21,7 +21,7 @@ ```json { "require": { - "imiphp/imi-macro": "~2.1.0" + "imiphp/imi-macro": "~3.0.0" } } ``` diff --git a/doc/components/meter/index.md b/doc/components/meter/index.md index bf7ab40d65..4555ec2cc2 100644 --- a/doc/components/meter/index.md +++ b/doc/components/meter/index.md @@ -10,10 +10,10 @@ imi 接入了服务指标监控能力,提供了 [imi-meter](https://github.com **支持的中间件:** -* [x] [Prometheus](/v2.1/components/meter/prometheus.html) +* [x] [Prometheus](/v3.0/components/meter/prometheus.html) -* [x] [InfluxDB](/v2.1/components/meter/influxdb.html) +* [x] [InfluxDB](/v3.0/components/meter/influxdb.html) -* [x] [TDengine](/v2.1/components/meter/tdengine.html) +* [x] [TDengine](/v3.0/components/meter/tdengine.html) …… diff --git a/doc/components/meter/influxdb.md b/doc/components/meter/influxdb.md index cea490289f..a3dd10af98 100644 --- a/doc/components/meter/influxdb.md +++ b/doc/components/meter/influxdb.md @@ -16,11 +16,11 @@ imi 支持将服务指标监控的数据写入 InfluxDB。 ## 安装 -`composer require imiphp/imi-influxdb:~2.1.0` +`composer require imiphp/imi-influxdb:~3.0.0` ## 使用说明 -imi-influxdb 基础配置和使用说明详见:[链接](/v2.1/components/influxdb.html) +imi-influxdb 基础配置和使用说明详见:[链接](/v3.0/components/influxdb.html) ### 服务指标监控 @@ -30,7 +30,7 @@ imi-influxdb 基础配置和使用说明详见:[链接](/v2.1/components/influ #### 安装所需组件 -`composer require imiphp/imi-meter:~2.1.0` +`composer require imiphp/imi-meter:~3.0.0` #### 配置 diff --git a/doc/components/meter/prometheus.md b/doc/components/meter/prometheus.md index e58f705adb..2a9db43caa 100644 --- a/doc/components/meter/prometheus.md +++ b/doc/components/meter/prometheus.md @@ -21,7 +21,7 @@ imi-prometheus: ## 安装 -`composer require imiphp/imi-prometheus:~2.1.0` +`composer require imiphp/imi-prometheus:~3.0.0` ## 使用说明 diff --git a/doc/components/meter/tdengine.md b/doc/components/meter/tdengine.md index 0f4279ce22..50ab146714 100644 --- a/doc/components/meter/tdengine.md +++ b/doc/components/meter/tdengine.md @@ -21,7 +21,7 @@ imi 支持将服务指标监控的数据写入 TDengine。 ### InfluxDB 兼容接口 -这个写入方式主要依赖 imi-influxdb,文档请移步:[链接](/v2.1/components/meter/influxdb.html) +这个写入方式主要依赖 imi-influxdb,文档请移步:[链接](/v3.0/components/meter/influxdb.html) 在 InfluxDB 配置基础上,只需要做如下修改,即可兼容 TDengine: diff --git a/doc/components/mq/amqp.md b/doc/components/mq/amqp.md index 6d59d4622a..314a7110ba 100644 --- a/doc/components/mq/amqp.md +++ b/doc/components/mq/amqp.md @@ -17,7 +17,7 @@ Github: ```json { "require": { - "imiphp/imi-amqp": "~2.1.0" + "imiphp/imi-amqp": "~3.0.0" } } ``` @@ -477,7 +477,7 @@ class TestProcess extends BaseProcess 适合计算密集型场景、消费量非常多的场景。 -进程池写法参考:[链接](/v2.1/components/process-pool/swoole.html) +进程池写法参考:[链接](/v3.0/components/process-pool/swoole.html) 启动消费者写法参考上面的即可。 diff --git a/doc/components/mq/kafka.md b/doc/components/mq/kafka.md index 9c123f0aea..170dce9f40 100644 --- a/doc/components/mq/kafka.md +++ b/doc/components/mq/kafka.md @@ -17,7 +17,7 @@ ```json { "require": { - "imiphp/imi-kafka": "~2.1.0" + "imiphp/imi-kafka": "~3.0.0" } } ``` diff --git a/doc/components/mq/redis.md b/doc/components/mq/redis.md index 5400ea9327..352ffbe1be 100644 --- a/doc/components/mq/redis.md +++ b/doc/components/mq/redis.md @@ -24,7 +24,7 @@ ```json { "require": { - "imiphp/imi-queue": "~2.1.0" + "imiphp/imi-queue": "~3.0.0" } } ``` diff --git a/doc/components/mq/redisStream.md b/doc/components/mq/redisStream.md index 0a3b4a6645..56b4e0718b 100644 --- a/doc/components/mq/redisStream.md +++ b/doc/components/mq/redisStream.md @@ -24,7 +24,7 @@ ```json { "require": { - "imiphp/imi-queue": "~2.1.0" + "imiphp/imi-queue": "~3.0.0" } } ``` diff --git a/doc/components/mqtt/server.md b/doc/components/mqtt/server.md index 1db65f346e..f9f6ab6eef 100644 --- a/doc/components/mqtt/server.md +++ b/doc/components/mqtt/server.md @@ -8,7 +8,7 @@ MQTT是一个基于客户端-服务器的消息发布/订阅传输协议。MQTT 安装:`composer require imiphp/imi-mqtt` -示例项目:`composer create-project imiphp/project-mqtt:~2.1.0` +示例项目:`composer create-project imiphp/project-mqtt:~3.0.0` ## 配置 diff --git a/doc/components/orm/RDModel.md b/doc/components/orm/RDModel.md index 424a6846be..e6dbecf3c4 100644 --- a/doc/components/orm/RDModel.md +++ b/doc/components/orm/RDModel.md @@ -148,7 +148,7 @@ foreach ($list2 as $row) ### 查询时指定字段 -请使用 `@Sql` 注解建模,参考文档:[链接](/v2.1/components/orm/RDModel/definition.html#@Sql) +请使用 `@Sql` 注解建模,参考文档:[链接](/v3.0/components/orm/RDModel/definition.html#@Sql) 不推荐的写法: diff --git a/doc/components/orm/RDModel/definition.md b/doc/components/orm/RDModel/definition.md index 591e096a91..2bebd98fa5 100644 --- a/doc/components/orm/RDModel/definition.md +++ b/doc/components/orm/RDModel/definition.md @@ -22,7 +22,7 @@ imi 的模型类里一般不写逻辑代码,模型类的一个对象就代表 `@DDL` 定义表结构的 SQL 语句 -> 建议使用模型生成工具:[链接](/v2.1/dev/generate/model.html) +> 建议使用模型生成工具:[链接](/v3.0/dev/generate/model.html) 具体定义看下面代码: @@ -551,7 +551,7 @@ ID 生成器指定参数: `@Id(index=false, generator=\Imi\Snowflake\Model\SnowflakeGenerator::class, generatorOptions={"name"="雪花算法配置名称"})` -> 雪花算法配置请参考:[链接](/v2.1/components/snowflake.html#%E9%85%8D%E7%BD%AE) +> 雪花算法配置请参考:[链接](/v3.0/components/snowflake.html#%E9%85%8D%E7%BD%AE) #### 自定义发号器 diff --git a/doc/components/orm/index.md b/doc/components/orm/index.md index 96046db375..abe993d46d 100644 --- a/doc/components/orm/index.md +++ b/doc/components/orm/index.md @@ -10,7 +10,7 @@ imi 中目前支持两个模型:数据库模型、内存表模型 在 imi 框架中,提供了一个模型生成工具。使用该工具生成的模型,在使用时无需手动定义字段,支持 IDE 代码提示。 -模型生成命令使用说明:[链接](/v2.1/dev/generate/model.html) +模型生成命令使用说明:[链接](/v3.0/dev/generate/model.html) ## 模型字段和序列化 diff --git a/doc/components/orm/migration.md b/doc/components/orm/migration.md index 66c34ad69d..64cbac0206 100644 --- a/doc/components/orm/migration.md +++ b/doc/components/orm/migration.md @@ -24,7 +24,7 @@ imi 的数据库迁移依赖模型功能,支持:使用图形化工具、手 ## 安装 -`composer require imiphp/imi-migration:~2.1.0` +`composer require imiphp/imi-migration:~3.0.0` ## 使用说明 diff --git a/doc/components/rate-limit.md b/doc/components/rate-limit.md index f9359909f7..1964e7847f 100644 --- a/doc/components/rate-limit.md +++ b/doc/components/rate-limit.md @@ -15,7 +15,7 @@ ```json { "require": { - "imiphp/imi-rate-limit": "~2.1.0" + "imiphp/imi-rate-limit": "~3.0.0" } } ``` diff --git a/doc/components/rpc/grpc-proxy.md b/doc/components/rpc/grpc-proxy.md index a710deaf29..67b2a008a4 100644 --- a/doc/components/rpc/grpc-proxy.md +++ b/doc/components/rpc/grpc-proxy.md @@ -12,13 +12,13 @@ imi v2.1.22 新加入的 gRPC HTTP 代理网关,作用是可以用 HTTP + JSON ### proto 文件生成 PHP 代码 -这一步和 [gRPC 服务开发](/v2.1/components/rpc/grpc.html#%E6%9C%8D%E5%8A%A1%E5%92%8C%E6%B6%88%E6%81%AF%E6%A0%BC%E5%BC%8F%E5%AE%9A%E4%B9%89)一样,就不再赘述。 +这一步和 [gRPC 服务开发](/v3.0/components/rpc/grpc.html#%E6%9C%8D%E5%8A%A1%E5%92%8C%E6%B6%88%E6%81%AF%E6%A0%BC%E5%BC%8F%E5%AE%9A%E4%B9%89)一样,就不再赘述。 ### 配置 gRPC 连接池 因为我们服务端是代理网关,其实就是作为客户端去连服务端,所以要配置连接池。 -可参考 [gRPC 服务开发](/v2.1/components/rpc/grpc.html#%E5%AE%A2%E6%88%B7%E7%AB%AF)。 +可参考 [gRPC 服务开发](/v3.0/components/rpc/grpc.html#%E5%AE%A2%E6%88%B7%E7%AB%AF)。 ### 绑定 gRPC 接口(非必须) diff --git a/doc/components/rpc/grpc.md b/doc/components/rpc/grpc.md index 60380bd3a7..4826a67724 100644 --- a/doc/components/rpc/grpc.md +++ b/doc/components/rpc/grpc.md @@ -19,7 +19,7 @@ Github: ```json { "require": { - "imiphp/imi-grpc": "~2.1.0" + "imiphp/imi-grpc": "~3.0.0" } } ``` @@ -28,7 +28,7 @@ Github: --- -你也可以直接创建 imi gRPC 骨架项目:`composer create-project imiphp/project-grpc:~2.1.0` +你也可以直接创建 imi gRPC 骨架项目:`composer create-project imiphp/project-grpc:~3.0.0` ## 使用说明 diff --git a/doc/components/rpc/hprose.md b/doc/components/rpc/hprose.md index 8f31811fc1..d4d1dd4836 100644 --- a/doc/components/rpc/hprose.md +++ b/doc/components/rpc/hprose.md @@ -17,7 +17,7 @@ Github: ```json { "require": { - "imiphp/imi-hprose": "~2.1.0" + "imiphp/imi-hprose": "~3.0.0" } } ``` diff --git a/doc/components/serviceDiscovery/index.md b/doc/components/serviceDiscovery/index.md index 918e80a290..84b8598470 100644 --- a/doc/components/serviceDiscovery/index.md +++ b/doc/components/serviceDiscovery/index.md @@ -28,7 +28,7 @@ #### Nacos -**安装:**`composer require imiphp/imi-nacos:~2.1.0 imiphp/imi-service:~2.1.0` +**安装:**`composer require imiphp/imi-nacos:~3.0.0 imiphp/imi-service:~3.0.0` **配置:** diff --git a/doc/components/serviceRegistry/index.md b/doc/components/serviceRegistry/index.md index 2e0a6f49d3..0a23a9cc83 100644 --- a/doc/components/serviceRegistry/index.md +++ b/doc/components/serviceRegistry/index.md @@ -24,7 +24,7 @@ ### Nacos -**安装:**`composer require imiphp/imi-nacos:~2.1.0 imiphp/imi-service:~2.1.0` +**安装:**`composer require imiphp/imi-nacos:~3.0.0 imiphp/imi-service:~3.0.0` **配置:** diff --git a/doc/components/shared-memory.md b/doc/components/shared-memory.md index ef8f7a8c71..e642c4994a 100644 --- a/doc/components/shared-memory.md +++ b/doc/components/shared-memory.md @@ -13,7 +13,7 @@ ```json { "require": { - "imiphp/imi-shared-memory": "~2.1.0" + "imiphp/imi-shared-memory": "~3.0.0" } } ``` diff --git a/doc/components/smarty.md b/doc/components/smarty.md index c945d76e6d..c908edd18e 100644 --- a/doc/components/smarty.md +++ b/doc/components/smarty.md @@ -13,7 +13,7 @@ ```json { "require": { - "imiphp/imi-smarty": "~2.1.0" + "imiphp/imi-smarty": "~3.0.0" } } ``` diff --git a/doc/components/snowflake.md b/doc/components/snowflake.md index c5609d0992..6e2e824f68 100644 --- a/doc/components/snowflake.md +++ b/doc/components/snowflake.md @@ -15,7 +15,7 @@ Github: ```json { "require": { - "imiphp/imi-snowflake": "~2.1.0" + "imiphp/imi-snowflake": "~3.0.0" } } ``` diff --git a/doc/components/swoole-tracker.md b/doc/components/swoole-tracker.md index 4b1d24245f..23c6611a79 100644 --- a/doc/components/swoole-tracker.md +++ b/doc/components/swoole-tracker.md @@ -35,7 +35,7 @@ Swoole Tracker: ```json { "require": { - "imiphp/imi-swoole-tracker": "~2.1.0" + "imiphp/imi-swoole-tracker": "~3.0.0" } } ``` diff --git a/doc/components/tcpServer/controller.md b/doc/components/tcpServer/controller.md index 740deac584..66c2f170be 100644 --- a/doc/components/tcpServer/controller.md +++ b/doc/components/tcpServer/controller.md @@ -95,7 +95,7 @@ $this->server->groupCall('组名', 'push', ['success'=>true]); ### $server -详见:[链接](/v2.1/core/server.html) +详见:[链接](/v3.0/core/server.html) ### $data diff --git a/doc/components/tracing/index.md b/doc/components/tracing/index.md index f237e18482..950e3659b3 100644 --- a/doc/components/tracing/index.md +++ b/doc/components/tracing/index.md @@ -10,10 +10,10 @@ **支持的中间件:** -* [x] [Swoole Tracker](/v2.1/components/swoole-tracker.html) +* [x] [Swoole Tracker](/v3.0/components/swoole-tracker.html) -* [x] [Zipkin](/v2.1/components/tracing/opentracing.html#Zipkin) +* [x] [Zipkin](/v3.0/components/tracing/opentracing.html#Zipkin) -* [x] [Jaeger](/v2.1/components/tracing/opentracing.html#Jaeger) +* [x] [Jaeger](/v3.0/components/tracing/opentracing.html#Jaeger) …… diff --git a/doc/components/tracing/opentracing.md b/doc/components/tracing/opentracing.md index b4e5081592..f1a2483547 100644 --- a/doc/components/tracing/opentracing.md +++ b/doc/components/tracing/opentracing.md @@ -175,7 +175,7 @@ Jaeger 是受 Dapper 和 OpenZipkin 的启发,由 Uber Technologies 创建的 #### 安装 Jaeger 所需组件 -`composer require imiphp/imi-opentracing:~2.1.0 jonahgeorge/jaeger-client-php` +`composer require imiphp/imi-opentracing:~3.0.0 jonahgeorge/jaeger-client-php` #### Jaeger 配置 @@ -273,7 +273,7 @@ Zipkin是 Twitter 的一个开源项目,基于 Google Dapper 实现。 #### 安装 Zipkin 所需组件 -`composer require imiphp/imi-opentracing:~2.1.0 jcchavezs/zipkin-opentracing` +`composer require imiphp/imi-opentracing:~3.0.0 jcchavezs/zipkin-opentracing` #### Zipkin 配置 diff --git a/doc/components/udpServer/controller.md b/doc/components/udpServer/controller.md index 91e687294a..6b1f0515cd 100644 --- a/doc/components/udpServer/controller.md +++ b/doc/components/udpServer/controller.md @@ -92,7 +92,7 @@ return ['success'=>true]; ### $server -详见:[链接](/v2.1/core/server.html) +详见:[链接](/v3.0/core/server.html) ### $data diff --git a/doc/components/websocketServer/httpController.md b/doc/components/websocketServer/httpController.md index 5e494651f7..cf34d6b439 100644 --- a/doc/components/websocketServer/httpController.md +++ b/doc/components/websocketServer/httpController.md @@ -16,6 +16,6 @@ parserClass 指定的就是处理器类,作用就是接收到数据后自动解码为对象或数组,发送时自动将数组或对象编码为相应数据。 -内置支持的类详见:[链接](/v2.1/components/server/dataParser.html) +内置支持的类详见:[链接](/v3.0/components/server/dataParser.html) > 此方法指定的处理器,可能会影响 `\Imi\Server\Server` 工具类的推送消息,强烈建议在配置文件中指定。 diff --git a/doc/components/websocketServer/reconnect.md b/doc/components/websocketServer/reconnect.md index 5557506445..a7f7a058b4 100644 --- a/doc/components/websocketServer/reconnect.md +++ b/doc/components/websocketServer/reconnect.md @@ -12,4 +12,4 @@ > 断线重连视频介绍: -使用文档详见:[链接](/v2.1/components/websocketServer/session.html) +使用文档详见:[链接](/v3.0/components/websocketServer/session.html) diff --git a/doc/components/websocketServer/session.md b/doc/components/websocketServer/session.md index 9a627d6c95..15d260fa3b 100644 --- a/doc/components/websocketServer/session.md +++ b/doc/components/websocketServer/session.md @@ -34,7 +34,7 @@ ConnectionContext::use(function($data){ ## 方法列表 -上下文操作可以参考([请求上下文](/v2.1/core/requestContext.html)) +上下文操作可以参考([请求上下文](/v3.0/core/requestContext.html)) ```php /** diff --git a/doc/components/websocketServer/websocketController.md b/doc/components/websocketServer/websocketController.md index b5e5946b07..4a7129f222 100644 --- a/doc/components/websocketServer/websocketController.md +++ b/doc/components/websocketServer/websocketController.md @@ -117,7 +117,7 @@ $this->server->groupCall('组名', 'push', ['success'=>true]); ### $server -详见:[链接](/v2.1/core/server.html) +详见:[链接](/v3.0/core/server.html) ### $frame diff --git a/doc/core/container.md b/doc/core/container.md index 160556d472..afd98e6ea9 100644 --- a/doc/core/container.md +++ b/doc/core/container.md @@ -178,7 +178,7 @@ $obj = ServerManager::getServer()->getContainer()->getBean('aaa', 1); 请求上下文容器中存储的对象是针对当前请求有效的,请求结束后会自动销毁。 -有关更多细节可以参考[请求上下文](/v2.1/core/requestContext.html)。 +有关更多细节可以参考[请求上下文](/v3.0/core/requestContext.html)。 请求上下文容器可以为每个请求提供独立的容器实例,以存储请求处理中所需的对象,例如请求参数、数据库连接等。请求上下文容器的使用可以避免多个请求之间的对象冲突,提高应用程序的可靠性和稳定性。 diff --git a/doc/dev/generate/swagger.md b/doc/dev/generate/swagger.md index 44ceb5db4a..346dfdd8a1 100644 --- a/doc/dev/generate/swagger.md +++ b/doc/dev/generate/swagger.md @@ -21,7 +21,7 @@ Github: ```json { "require": { - "imiphp/imi-apidoc": "~2.1.0" + "imiphp/imi-apidoc": "~3.0.0" } } ``` diff --git a/doc/mddoc.json b/doc/mddoc.json index 3de45d6afd..5fed30dbdc 100644 --- a/doc/mddoc.json +++ b/doc/mddoc.json @@ -1,3 +1,3 @@ { - "name": "imi 2.1 开发文档" + "name": "imi 3.0 开发文档" } \ No newline at end of file diff --git a/doc/utils/Server.md b/doc/utils/Server.md index 19ba6b13da..b3cfe93c01 100644 --- a/doc/utils/Server.md +++ b/doc/utils/Server.md @@ -445,4 +445,4 @@ $count = Server::getConnectionCount(); ### 其它 -> 连接上下文的使用:[链接](/v2.1/components/websocketServer/session.html) +> 连接上下文的使用:[链接](/v3.0/components/websocketServer/session.html) diff --git a/doc/utils/Swoole.md b/doc/utils/Swoole.md index e9b410b5e4..6712eb0679 100644 --- a/doc/utils/Swoole.md +++ b/doc/utils/Swoole.md @@ -6,7 +6,7 @@ **类名:** `Imi\Swoole\SwooleWorker` -**继承:** `Imi\Worker` (详见:[链接](/v2.1/utils/Worker.html)) +**继承:** `Imi\Worker` (详见:[链接](/v3.0/utils/Worker.html)) ### 方法 diff --git a/mddoc/template/html/article.php b/mddoc/template/html/article.php index 3403d1f0e1..a0356357e8 100644 --- a/mddoc/template/html/article.php +++ b/mddoc/template/html/article.php @@ -5,7 +5,7 @@ <?php echo $pageTitle; ?> @@ -33,7 +33,7 @@