From 6930c4187398733ecbf3824db3ca30c0ce53f617 Mon Sep 17 00:00:00 2001 From: Brandon Flude Date: Fri, 13 Nov 2020 15:42:14 -0500 Subject: [PATCH] update for compatibility with symfony 5 #65 add return values to commands add symfony 5 instructions to readme --- Command/BuildCommand.php | 2 ++ Command/ControlCommand.php | 2 ++ Command/InitCommand.php | 2 ++ Command/KillCommand.php | 2 ++ Command/RebuildCommand.php | 2 ++ Command/RestartCommand.php | 2 ++ README.md | 12 ++++++++++++ composer.json | 9 +++++---- 8 files changed, 29 insertions(+), 4 deletions(-) diff --git a/Command/BuildCommand.php b/Command/BuildCommand.php index 7b7c48a..23f9210 100644 --- a/Command/BuildCommand.php +++ b/Command/BuildCommand.php @@ -21,5 +21,7 @@ protected function execute(InputInterface $input, OutputInterface $output) { $this->rabbitMqSupervisor->setWaitForSupervisord((bool) $input->getOption('wait-for-supervisord')); $this->rabbitMqSupervisor->build(); + + return 0; } } diff --git a/Command/ControlCommand.php b/Command/ControlCommand.php index 74c9f92..cf01345 100644 --- a/Command/ControlCommand.php +++ b/Command/ControlCommand.php @@ -42,5 +42,7 @@ protected function execute(InputInterface $input, OutputInterface $output) $input->getArgument('cmd') )); } + + return 0; } } diff --git a/Command/InitCommand.php b/Command/InitCommand.php index 2861163..f92961f 100644 --- a/Command/InitCommand.php +++ b/Command/InitCommand.php @@ -18,5 +18,7 @@ protected function configure() protected function execute(InputInterface $input, OutputInterface $output) { $this->rabbitMqSupervisor->init(); + + return 0; } } diff --git a/Command/KillCommand.php b/Command/KillCommand.php index d22d0ac..49a9c85 100644 --- a/Command/KillCommand.php +++ b/Command/KillCommand.php @@ -20,5 +20,7 @@ protected function configure() protected function execute(InputInterface $input, OutputInterface $output) { $this->rabbitMqSupervisor->kill($input->getArgument('signal')); + + return 0; } } diff --git a/Command/RebuildCommand.php b/Command/RebuildCommand.php index 035825f..8e51366 100644 --- a/Command/RebuildCommand.php +++ b/Command/RebuildCommand.php @@ -21,5 +21,7 @@ protected function execute(InputInterface $input, OutputInterface $output) { $this->rabbitMqSupervisor->setWaitForSupervisord((bool) $input->getOption('wait-for-supervisord')); $this->rabbitMqSupervisor->rebuild(); + + return 0; } } diff --git a/Command/RestartCommand.php b/Command/RestartCommand.php index 09b8bf4..614e8ab 100644 --- a/Command/RestartCommand.php +++ b/Command/RestartCommand.php @@ -21,5 +21,7 @@ protected function execute(InputInterface $input, OutputInterface $output) { $this->rabbitMqSupervisor->setWaitForSupervisord((bool) $input->getOption('wait-for-supervisord')); $this->rabbitMqSupervisor->restart(); + + return 0; } } diff --git a/README.md b/README.md index 09557e3..f6dab7f 100644 --- a/README.md +++ b/README.md @@ -40,6 +40,18 @@ public function registerBundles() } ``` +Symfony 5: + +```php +// config/bundles.php +return [ + ... + Phobetor\RabbitMqSupervisorBundle\RabbitMqSupervisorBundle::class => ["all" => true], + ... +]; + +``` + ## Zero Configuration RabbitMQ supervisor bundle works out of the box with a predefined configuration. If you leave it this way you will end diff --git a/composer.json b/composer.json index 1f2c19e..a97bed5 100644 --- a/composer.json +++ b/composer.json @@ -9,7 +9,8 @@ "supervisord", "symfony2", "symfony3", - "symfony4" + "symfony4", + "symfony5" ], "homepage": "https://github.com/Phobetor/rabbitmq-supervisor-bundle", "authors": [ @@ -20,9 +21,9 @@ } ], "require": { - "symfony/framework-bundle": "~2.5|~3.0|~4.0", - "symfony/console": "~2.5|~3.0|~4.0", - "symfony/process": "~2.5|~3.0|~4.0" + "symfony/framework-bundle": "~2.5|~3.0|~4.0|~5.0", + "symfony/console": "~2.5|~3.0|~4.0|~5.0", + "symfony/process": "~2.5|~3.0|~4.0|~5.0" }, "suggest": { "php-amqplib/rabbitmq-bundle": "The rabbitmq bundle for symfony which this bundle takes the consumer information from",