@@ -18,7 +18,7 @@ class RezzzaCommandBusExtension extends Extension
18
18
/**
19
19
* {@inheritdoc}
20
20
*/
21
- public function load (array $ configs , ContainerBuilder $ container )
21
+ public function load (array $ configs , ContainerBuilder $ container ): void
22
22
{
23
23
$ processor = new Processor ();
24
24
$ config = $ processor ->processConfiguration (new Configuration (), $ configs );
@@ -35,7 +35,7 @@ public function load(array $configs, ContainerBuilder $container)
35
35
$ loader ->load ('services.xml ' );
36
36
}
37
37
38
- private function createBus ($ name , array $ config , ContainerBuilder $ container , $ loggerNormalizer , array $ logLevels )
38
+ private function createBus ($ name , array $ config , ContainerBuilder $ container , $ loggerNormalizer , array $ logLevels ): void
39
39
{
40
40
$ providerName = current (array_keys ($ config ));
41
41
$ commandBusServiceName = $ this ->getCommandBusServiceName ($ name );
@@ -68,7 +68,7 @@ private function createBus($name, array $config, ContainerBuilder $container, $l
68
68
}
69
69
}
70
70
71
- private function createRabbitMqBusCommandBus ($ commandBusServiceName , $ config , ContainerBuilder $ container )
71
+ private function createRabbitMqBusCommandBus ($ commandBusServiceName , $ config , ContainerBuilder $ container ): void
72
72
{
73
73
$ service = new Definition ('%rezzza_command_bus.old_sound_rabbit_bus.class% ' , [
74
74
new Reference ($ config ['producer_guesser ' ]),
@@ -87,7 +87,7 @@ private function createRabbitMqBusCommandBus($commandBusServiceName, $config, Co
87
87
}
88
88
}
89
89
90
- private function createSncRedisBusCommandBus ($ commandBusServiceName , $ config , ContainerBuilder $ container )
90
+ private function createSncRedisBusCommandBus ($ commandBusServiceName , $ config , ContainerBuilder $ container ): void
91
91
{
92
92
$ client = new Reference (sprintf ('snc_redis.%s_client ' , $ config ['client ' ]));
93
93
$ serializer = new Reference ($ config ['serializer ' ]);
@@ -114,7 +114,7 @@ private function createSncRedisBusCommandBus($commandBusServiceName, $config, Co
114
114
}
115
115
}
116
116
117
- private function createConsumerDefinition ($ name , Definition $ defaultProvider , array $ config , $ commandBusServiceName , ContainerBuilder $ container )
117
+ private function createConsumerDefinition ($ name , Definition $ defaultProvider , array $ config , $ commandBusServiceName , ContainerBuilder $ container ): void
118
118
{
119
119
$ consumerDefinition = new Definition ('%rezzza_command_bus.consumer.class% ' ,
120
120
[
@@ -165,7 +165,7 @@ private function createFailStrategyDefinition(array $config, $commandBusServiceN
165
165
}
166
166
}
167
167
168
- private function loadHandlers (array $ handlers , ContainerBuilder $ container )
168
+ private function loadHandlers (array $ handlers , ContainerBuilder $ container ): void
169
169
{
170
170
if (isset ($ handlers ['retry ' ])) {
171
171
$ config = $ handlers ['retry ' ];
@@ -194,7 +194,7 @@ private function loadHandlers(array $handlers, ContainerBuilder $container)
194
194
}
195
195
}
196
196
197
- private function decorateBus ($ busServiceId , ContainerBuilder $ container , $ loggerNormalizer , array $ logLevels )
197
+ private function decorateBus ($ busServiceId , ContainerBuilder $ container , $ loggerNormalizer , array $ logLevels ): void
198
198
{
199
199
$ originalBusServiceId = $ busServiceId .'.original ' ;
200
200
$ container
@@ -217,12 +217,12 @@ private function decorateBus($busServiceId, ContainerBuilder $container, $logger
217
217
;
218
218
}
219
219
220
- private function getCommandBusServiceName ($ commandBus )
220
+ private function getCommandBusServiceName ($ commandBus ): string
221
221
{
222
222
return sprintf ('rezzza_command_bus.command_bus.%s ' , $ commandBus );
223
223
}
224
224
225
- private function getPriorityValue ($ priority )
225
+ private function getPriorityValue ($ priority ): ? int
226
226
{
227
227
switch ($ priority ) {
228
228
case Configuration::PRIORITY_HIGH :
@@ -234,7 +234,7 @@ private function getPriorityValue($priority)
234
234
}
235
235
}
236
236
237
- private function createLoggerReference ()
237
+ private function createLoggerReference (): Reference
238
238
{
239
239
return new Reference ('logger ' , ContainerInterface::NULL_ON_INVALID_REFERENCE );
240
240
}
0 commit comments