protected function execute(InputInterface $input, OutputInterface $output) { try { $handler = $this->container->get('backup.handler'); $generic = BackupHandler::genericCommandArgumentsParse($input); $handler->injectInterfaces($output, $generic, "filesystem.json"); $handler->allowCmdOverride($input); $handler->configSpecification->requireConfig('directories:array'); $handler->addTask(array($this, 'createBackups')); $handler->run(); } catch (\Exception $e) { $this->container->get('notification.manager')->error("Error creating backups: " . $e->getMessage()); throw $e; } }
protected function execute(InputInterface $input, OutputInterface $output) { try { $handler = $this->container->get('backup.handler'); $generic = BackupHandler::genericCommandArgumentsParse($input); $handler->injectInterfaces($output, $generic, "database.json"); $handler->allowCmdOverride($input); new GenericDatabaseInstructions($handler); $handler->addTask(array($this, 'createBackups')); $handler->run(); } catch (\Exception $e) { $this->container->get('notification.manager')->error("Error creating backups: " . $e->getMessage()); throw $e; } }