-
Notifications
You must be signed in to change notification settings - Fork 240
feat(api): endpoint for centreon web upgrade #11307
Conversation
src/Core/Platform/Application/UseCase/UpdateVersions/UpdateVersions.php
Outdated
Show resolved
Hide resolved
src/Core/Platform/Infrastructure/Repository/LegacyReadVersionRepository.php
Outdated
Show resolved
Hide resolved
class LegacyWriteVersionRepository extends AbstractRepositoryDRB implements WriteVersionRepositoryInterface | ||
{ | ||
use LoggerTrait; | ||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
maybe you could define a constant INSTALL_DIR = '''; and use them in different methods ?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
done
* @param string $filePath | ||
* @return void | ||
*/ | ||
private function runSqlFile(string $filePath): void |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
this method has a high cyclomatic complexity and could be refactored
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I've just refactored most of the code by splitting in private methods
src/Core/Platform/Infrastructure/Repository/LegacyWriteVersionRepository.php
Outdated
Show resolved
Hide resolved
src/Core/Platform/Infrastructure/Repository/LegacyWriteVersionRepository.php
Outdated
Show resolved
Hide resolved
src/Core/Platform/Infrastructure/Repository/LegacyWriteVersionRepository.php
Outdated
Show resolved
Hide resolved
src/Core/Platform/Infrastructure/Repository/LegacyWriteVersionRepository.php
Outdated
Show resolved
Hide resolved
src/Core/Platform/Infrastructure/Repository/LegacyWriteVersionRepository.php
Outdated
Show resolved
Hide resolved
src/Core/Platform/Application/Repository/WriteVersionRepositoryInterface.php
Outdated
Show resolved
Hide resolved
src/Core/Platform/Application/UseCase/UpdateVersions/UpdateVersions.php
Outdated
Show resolved
Hide resolved
src/Core/Platform/Application/UseCase/UpdateVersions/UpdateVersions.php
Outdated
Show resolved
Hide resolved
src/Core/Platform/Application/UseCase/UpdateVersions/UpdateVersions.php
Outdated
Show resolved
Hide resolved
src/Core/Platform/Infrastructure/Repository/LegacyReadVersionRepository.php
Outdated
Show resolved
Hide resolved
src/Core/Platform/Application/UseCase/UpdateVersions/UpdateVersions.php
Outdated
Show resolved
Hide resolved
src/Core/Platform/Application/UseCase/UpdateVersions/UpdateVersions.php
Outdated
Show resolved
Hide resolved
src/Core/Platform/Application/UseCase/UpdateVersions/UpdateVersions.php
Outdated
Show resolved
Hide resolved
src/Core/Platform/Application/UseCase/UpdateVersions/UpdateVersions.php
Outdated
Show resolved
Hide resolved
…sions.php Co-authored-by: Laurent Calvet <lcalvet@centreon.com>
src/Core/Platform/Application/UseCase/UpdateVersions/UpdateVersions.php
Outdated
Show resolved
Hide resolved
SonarQube Quality Gate |
Description
add endpoint for centreon web upgrade
this allows to execute all upgrade scripts in a single time via api
next steps :
Fixes MON-12296
Type of change
Target serie