File tree 3 files changed +17
-7
lines changed
3 files changed +17
-7
lines changed Original file line number Diff line number Diff line change @@ -103,7 +103,7 @@ public function getRouterProcessorName()
103
103
*/
104
104
public function createTransportRouterTopicName ($ name )
105
105
{
106
- return trim ( strtolower ( trim ( $ this ->prefix ). ' . ' . trim ($ name)), ' . ' );
106
+ return $ this ->getQueueName ($ name );
107
107
}
108
108
109
109
/**
@@ -113,7 +113,7 @@ public function createTransportRouterTopicName($name)
113
113
*/
114
114
public function createTransportQueueName ($ name )
115
115
{
116
- return trim ( strtolower ( trim ( $ this ->prefix ). ' . ' . trim ( $ this -> appName ). ' . ' . trim ( $ name)), ' . ' );
116
+ return $ this ->getQueueName ( $ name );
117
117
}
118
118
119
119
/**
@@ -154,4 +154,14 @@ public static function create(
154
154
$ routerProcessorName ?: 'router '
155
155
);
156
156
}
157
+
158
+ /**
159
+ * @param string $name
160
+ *
161
+ * @return string
162
+ */
163
+ private function getQueueName ($ name )
164
+ {
165
+ return trim (strtolower (trim ($ this ->prefix ).'. ' .trim ($ this ->appName ).'. ' .trim ($ name )), '. ' );
166
+ }
157
167
}
Original file line number Diff line number Diff line change @@ -73,7 +73,7 @@ public function testShouldCreateRouterTopicName()
73
73
'aRouterProcessorName '
74
74
);
75
75
76
- $ this ->assertEquals ('aprefix.aname ' , $ config ->createTransportRouterTopicName ('aName ' ));
76
+ $ this ->assertEquals ('aprefix.aapp. aname ' , $ config ->createTransportRouterTopicName ('aName ' ));
77
77
}
78
78
79
79
public function testShouldCreateProcessorQueueName ()
Original file line number Diff line number Diff line change @@ -483,7 +483,7 @@ public function testShouldSetupBroker()
483
483
$ managementClient
484
484
->expects ($ this ->at (0 ))
485
485
->method ('declareExchange ' )
486
- ->with ('prefix.routertopic ' , [
486
+ ->with ('prefix.app. routertopic ' , [
487
487
'type ' => 'fanout ' ,
488
488
'durable ' => true ,
489
489
'auto_delete ' => false ,
@@ -503,7 +503,7 @@ public function testShouldSetupBroker()
503
503
$ managementClient
504
504
->expects ($ this ->at (2 ))
505
505
->method ('bind ' )
506
- ->with ('prefix.routertopic ' , 'prefix.app.routerqueue ' , 'prefix.app.routerqueue ' )
506
+ ->with ('prefix.app. routertopic ' , 'prefix.app.routerqueue ' , 'prefix.app.routerqueue ' )
507
507
;
508
508
$ managementClient
509
509
->expects ($ this ->at (3 ))
@@ -528,7 +528,7 @@ public function testShouldSetupBroker()
528
528
$ logger
529
529
->expects ($ this ->at (0 ))
530
530
->method ('debug ' )
531
- ->with ('[RabbitMqStompDriver] Declare router exchange: prefix.routertopic ' )
531
+ ->with ('[RabbitMqStompDriver] Declare router exchange: prefix.app. routertopic ' )
532
532
;
533
533
$ logger
534
534
->expects ($ this ->at (1 ))
@@ -538,7 +538,7 @@ public function testShouldSetupBroker()
538
538
$ logger
539
539
->expects ($ this ->at (2 ))
540
540
->method ('debug ' )
541
- ->with ('[RabbitMqStompDriver] Bind router queue to exchange: prefix.app.routerqueue -> prefix.routertopic ' )
541
+ ->with ('[RabbitMqStompDriver] Bind router queue to exchange: prefix.app.routerqueue -> prefix.app. routertopic ' )
542
542
;
543
543
$ logger
544
544
->expects ($ this ->at (3 ))
You can’t perform that action at this time.
0 commit comments