This commit is contained in:
2025-11-14 16:39:00 +08:00
parent 695b046c8a
commit 46073d666c
3 changed files with 36 additions and 1 deletions
+34
View File
@@ -0,0 +1,34 @@
<?php
declare(strict_types=1);
namespace App\Command;
use Hyperf\Command\Command as HyperfCommand;
use Hyperf\Command\Annotation\Command;
use Psr\Container\ContainerInterface;
use App\Platform\Tools\Request\CompanyRequest;
use App\Model\Company;
use Hyperf\DbConnection\Db;
use App\Utils\Log;
use Exception;
#[Command]
class AppQueuePushKm extends HyperfCommand
{
public function __construct(protected ContainerInterface $container)
{
parent::__construct('app:queue-push:km');
}
public function configure()
{
parent::configure();
$this->setDescription('Test push message with KM data');
}
public function handle()
{
}
}
+1 -1
View File
@@ -13,7 +13,7 @@
### 架构特点 ### 架构特点
- **VHost 隔离**:按应用划分 VHost,支持多业务复用 - **VHost 隔离**:按应用划分 VHost,支持多业务复用 使用 `Classic` Vhost 模式
- **Exchange 隔离**:每个平台独立 Exchange,通过权限控制访问 - **Exchange 隔离**:每个平台独立 Exchange,通过权限控制访问
- **单队列设计**:每种数据类型一个队列,所有平台共享(orders.queue/products.queue/refunds.queue/inventory.queue),保证严格 FIFO 顺序 - **单队列设计**:每种数据类型一个队列,所有平台共享(orders.queue/products.queue/refunds.queue/inventory.queue),保证严格 FIFO 顺序
- **独立消费者**:每种数据类型配备独立消费者,采用批处理 + prefetch + 适配器模式,提升吞吐与稳定性 - **独立消费者**:每种数据类型配备独立消费者,采用批处理 + prefetch + 适配器模式,提升吞吐与稳定性
+1
View File
@@ -1,3 +1,4 @@
1. 使用 docs/RabbitMQ.md 建立 MQ 内部的数据分层和结构
1. 拉取 km 数据放入队列 (暂不作请求规范) 1. 拉取 km 数据放入队列 (暂不作请求规范)
2. 拉取 loop 数据放入队列(暂不作请求规范) 2. 拉取 loop 数据放入队列(暂不作请求规范)
3. 执行数据消费 3. 执行数据消费