99use Symfony \Component \Config \Loader as ConfigLoader ;
1010use Symfony \Component \Console \Application ;
1111use Symfony \Component \DependencyInjection \ContainerBuilder ;
12+ use Symfony \Component \DependencyInjection \Exception \LogicException ;
1213use Symfony \Component \DependencyInjection \Exception \ServiceNotFoundException ;
1314use Symfony \Component \DependencyInjection \Loader as DependencyInjectionLoader ;
1415use Symfony \Component \DependencyInjection \Reference ;
1516use Symfony \Component \HttpKernel \DependencyInjection \Extension ;
1617use Symfony \Component \Messenger \MessageBusInterface ;
17- use Symfony \Component \Serializer \SerializerInterface ;
18- use Symfony \Component \Validator \Validator \ValidatorInterface ;
1918use Yokai \Batch \Bridge \Doctrine \DBAL \DoctrineDBALJobExecutionStorage ;
2019use Yokai \Batch \Launcher \JobLauncherInterface ;
2120use Yokai \Batch \Storage \FilesystemJobExecutionStorage ;
@@ -114,7 +113,7 @@ private function configureStorage(ContainerBuilder $container, array $config): v
114113 try {
115114 $ defaultStorageDefinition = $ container ->getDefinition ($ defaultStorage );
116115 } catch (ServiceNotFoundException $ exception ) {
117- throw new \ LogicException (
116+ throw new LogicException (
118117 sprintf ('Configured default job execution storage service "%s" does not exists. ' , $ defaultStorage ),
119118 0 ,
120119 $ exception
@@ -130,7 +129,14 @@ private function configureStorage(ContainerBuilder $container, array $config): v
130129 foreach ($ interfaces as $ interface => $ required ) {
131130 if (!is_a ($ defaultStorageClass , $ interface , true )) {
132131 if ($ required ) {
133- throw new \LogicException ();//todo
132+ throw new LogicException (
133+ \sprintf (
134+ 'Job execution storage service "%s", is of class "%s", and must implements interface "%s". ' ,
135+ $ defaultStorage ,
136+ $ defaultStorageClass ,
137+ $ interface
138+ )
139+ );
134140 }
135141 continue ;
136142 }
0 commit comments