|
|
@@ -35,12 +35,16 @@ $rabbitMQ = [
|
|
|
*/
|
|
|
'exchanges' => [
|
|
|
[
|
|
|
- 'name' => 'exCommon',
|
|
|
- 'type' => 'direct' // direct
|
|
|
+ 'name' => 'commonExchange',
|
|
|
+ 'type' => 'direct'
|
|
|
],
|
|
|
[
|
|
|
- 'name' => 'exInform',
|
|
|
- 'type' => 'direct' // direct
|
|
|
+ 'name' => 'informExchange',
|
|
|
+ 'type' => 'direct'
|
|
|
+ ],
|
|
|
+ [
|
|
|
+ 'name' => 'openShopInitExchange',
|
|
|
+ 'type' => 'direct'
|
|
|
],
|
|
|
/*
|
|
|
[
|
|
|
@@ -67,7 +71,11 @@ $rabbitMQ = [
|
|
|
'passive' => false,
|
|
|
],
|
|
|
[
|
|
|
- 'name' => 'queueInform',
|
|
|
+ 'name' => 'informQueue',
|
|
|
+ 'passive' => false,
|
|
|
+ ],
|
|
|
+ [
|
|
|
+ 'name' => 'openShopInitQueue',
|
|
|
'passive' => false,
|
|
|
],
|
|
|
/*
|
|
|
@@ -103,13 +111,18 @@ $rabbitMQ = [
|
|
|
'bindings' => [
|
|
|
[
|
|
|
'queue' => 'queueCommon',
|
|
|
- 'exchange' => 'exCommon',
|
|
|
- 'routing_keys' => ['routeCommon'],
|
|
|
+ 'exchange' => 'commonExchange',
|
|
|
+ 'routing_keys' => ['commonRoute'],
|
|
|
+ ],
|
|
|
+ [
|
|
|
+ 'queue' => 'informQueue',
|
|
|
+ 'exchange' => 'informExchange',
|
|
|
+ 'routing_keys' => ['informRoute'],
|
|
|
],
|
|
|
[
|
|
|
- 'queue' => 'queueInform',
|
|
|
- 'exchange' => 'exInform',
|
|
|
- 'routing_keys' => ['routeInform'],
|
|
|
+ 'queue' => 'openShopInitQueue',
|
|
|
+ 'exchange' => 'openShopInitExchange',
|
|
|
+ 'routing_keys' => ['openShopInitRoute'],
|
|
|
],
|
|
|
/*
|
|
|
[
|
|
|
@@ -130,12 +143,16 @@ $rabbitMQ = [
|
|
|
*/
|
|
|
'producers' => [
|
|
|
[
|
|
|
- //常规生产者
|
|
|
- 'name' => 'producerCommon',
|
|
|
+ //通用生产者
|
|
|
+ 'name' => 'commonProducer',
|
|
|
],
|
|
|
[
|
|
|
- //通知模块生产者
|
|
|
- 'name' => 'producerInform',
|
|
|
+ //通知生产者
|
|
|
+ 'name' => 'informProducer',
|
|
|
+ ],
|
|
|
+ [
|
|
|
+ //通知生产者
|
|
|
+ 'name' => 'openShopInitProducer',
|
|
|
],
|
|
|
/*
|
|
|
[
|
|
|
@@ -155,16 +172,23 @@ $rabbitMQ = [
|
|
|
'consumers' => [
|
|
|
[
|
|
|
//常规消费者
|
|
|
- 'name' => 'consumerCommon',
|
|
|
+ 'name' => 'commonConsumer',
|
|
|
+ 'callbacks' => [
|
|
|
+ 'queueCommon' => '\common\components\rabbitmq\consumer\commonConsumer', //设定队列的数据给谁转回调而以,只是个配置
|
|
|
+ ],
|
|
|
+ ],
|
|
|
+ [
|
|
|
+ //通知
|
|
|
+ 'name' => 'informConsumer',
|
|
|
'callbacks' => [
|
|
|
- 'queueCommon' => '\common\components\rabbitmq\consumer\ImportDataConsumer', //设定队列的数据给谁转回调而以,只是个配置
|
|
|
+ 'informQueue' => '\common\components\rabbitmq\consumer\informConsumer', //设定队列的数据给谁转回调而以,只是个配置
|
|
|
],
|
|
|
],
|
|
|
[
|
|
|
- //通知模块消费者
|
|
|
- 'name' => 'consumerInform',
|
|
|
+ //授权公众号开店初始化
|
|
|
+ 'name' => 'openShopInitConsumer',
|
|
|
'callbacks' => [
|
|
|
- 'queueInform' => '\common\components\rabbitmq\consumer\InformConsumer', //设定队列的数据给谁转回调而以,只是个配置
|
|
|
+ 'informQueue' => '\common\components\rabbitmq\consumer\openShopInitConsumer', //设定队列的数据给谁转回调而以,只是个配置
|
|
|
],
|
|
|
],
|
|
|
/*
|