phuongna/rabbitmq
Composer 安装命令:
composer require phuongna/rabbitmq
包简介
Follow guide https://www.rabbitmq.com/ to create a library easy to use. For Laravel!
关键字:
README 文档
README
Installation
Install via composer
composer require phuongna/rabbitmq
Publish package assets
php artisan vendor:publish --provider="phuongna\rabbitmq\ServiceProvider"
Security
If you discover any security related issues, please email instead of using the issue tracker.
How to use
####Server as service
$this->rabbit = app('rabbitmq.queue')->connection('rabbitmq');
RabbitMQQueue::declareRPCServer($this->rabbit, xxx, function ($request) {
$this->rabbit->replyTo($request, dosomething($request));
});
####Client as service
$this->rabbit = app('rabbitmq.queue')->connection('rabbitmq');
$stringInput = json_encode(array);
RabbitMQQueue::declareRPCClient($this->rabbit, xxx, $stringInput);
统计信息
- 总下载量: 250
- 月度下载量: 0
- 日度下载量: 0
- 收藏数: 0
- 点击次数: 0
- 依赖项目数: 1
- 推荐数: 0
其他信息
- 授权协议: MIT
- 更新时间: 2021-07-23