From ffdcca01a5deba6a7dff3bd048b35a129f0481f9 Mon Sep 17 00:00:00 2001 From: Durga Sarat Chandra Maddu <44021874+Dmaddu@users.noreply.github.com> Date: Fri, 18 Feb 2022 12:14:42 +0530 Subject: [PATCH] updating error messages to be shown to end user (#6714) Signed-off-by: Durga Sarat Chandra Maddu --- .../automate-cli/cmd/chef-automate/upgrade.go | 22 +-- .../pkg/airgap/bundle_creator.go | 1 - .../pkg/converge/compiler.go | 2 +- .../pkg/manifest/client/http.go | 4 - .../pkg/manifest/provider_test.go | 78 +++++----- .../automate-deployment/pkg/server/server.go | 18 +-- .../pkg/server/server_test.go | 144 +++++++++--------- .../pkg/server/upgrade_status.go | 1 - 8 files changed, 128 insertions(+), 142 deletions(-) diff --git a/components/automate-cli/cmd/chef-automate/upgrade.go b/components/automate-cli/cmd/chef-automate/upgrade.go index 21058f367894..9e6833849de9 100644 --- a/components/automate-cli/cmd/chef-automate/upgrade.go +++ b/components/automate-cli/cmd/chef-automate/upgrade.go @@ -86,7 +86,6 @@ func runUpgradeCmd(cmd *cobra.Command, args []string) error { if upgradeRunCmdFlags.version != "" && offlineMode { return status.New(status.InvalidCommandArgsError, "--version and --airgap-bundle cannot be used together") } - //Todo(milestone) check if upgradeRunCmdFlags.version is compatible with current version. if offlineMode { writer.Title("Installing airgap install bundle") @@ -253,8 +252,11 @@ func statusUpgradeCmd(cmd *cobra.Command, args []string) error { if resp.IsAirgapped { writer.Printf("Automate is up-to-date with airgap bundle (%s)\n", resp.CurrentVersion) } else if resp.CurrentVersion < resp.LatestAvailableVersion { - writer.Printf("Automate is out-of-date (current version: %s; latest available: %s; airgapped: %v)\n", + writer.Printf("Automate is out-of-date (current version: %s; next available version: %s; is Airgapped: %v)\n", resp.CurrentVersion, resp.LatestAvailableVersion, resp.IsAirgapped) + if !resp.IsConvergeCompatable { + writer.Printf("Please manually run the major upgrade command to upgrade to %s\n", resp.LatestAvailableVersion) + } } else { writer.Printf("Automate is up-to-date (%s)\n", resp.CurrentVersion) } @@ -271,23 +273,13 @@ func statusUpgradeCmd(cmd *cobra.Command, args []string) error { if resp.IsAirgapped { writer.Titlef("Automate is upgrading to airgap bundle %s", resp.DesiredVersion) } else { - if !resp.IsConvergeCompatable { - writer.Printf("Automate is out-of-date (current version: %s; latest available: %s; airgapped: %v)\n", - resp.CurrentVersion, resp.LatestAvailableVersion, resp.IsAirgapped) - } else { - writer.Titlef("Automate is upgrading to %s", resp.DesiredVersion) - } + writer.Titlef("Automate is upgrading to %s", resp.DesiredVersion) } } else { if resp.IsAirgapped { writer.Titlef("Automate is upgrading to airgap bundle %s", resp.LatestAvailableVersion) } else { - if !resp.IsConvergeCompatable { - writer.Printf("Automate is out-of-date (current version: %s; latest available: %s; airgapped: %v)\n", - resp.CurrentVersion, resp.LatestAvailableVersion, resp.IsAirgapped) - } else { - writer.Titlef("Automate is upgrading to %s", resp.LatestAvailableVersion) - } + writer.Titlef("Automate is upgrading to %s", resp.LatestAvailableVersion) } } @@ -371,7 +363,7 @@ func init() { &upgradeRunCmdFlags.isMajorUpgrade, "major", false, - "will be used for major upgrade") + "This flag is only needed for major version upgrades") upgradeCmd.AddCommand(upgradeRunCmd) upgradeCmd.AddCommand(upgradeStatusCmd) diff --git a/components/automate-deployment/pkg/airgap/bundle_creator.go b/components/automate-deployment/pkg/airgap/bundle_creator.go index a4336ebfcca3..2c555508e640 100644 --- a/components/automate-deployment/pkg/airgap/bundle_creator.go +++ b/components/automate-deployment/pkg/airgap/bundle_creator.go @@ -240,7 +240,6 @@ func (creator *InstallBundleCreator) Create(progress InstallBundleCreatorProgres return "", err } - //Todo(milestone): Add a check to see if the latest manifest is compatible with the current version if creator.outputFile == "" { creator.outputFile = fmt.Sprintf("automate-%s.aib", m.Version()) } diff --git a/components/automate-deployment/pkg/converge/compiler.go b/components/automate-deployment/pkg/converge/compiler.go index 2b9f92526c92..742ad6b70bb2 100644 --- a/components/automate-deployment/pkg/converge/compiler.go +++ b/components/automate-deployment/pkg/converge/compiler.go @@ -342,7 +342,7 @@ func (phase *SelfUpgradePhase) Run(writer *eventWriter) error { if err != nil { return errors.Wrapf(err, "Could not parse deployment-service release %s", desiredReleaseStr) } - //Todo(milestone) check if this code involves in upgrade process, if so modify the below comparison + if curRel < desRel { // only upgrade if the release is newer. this is a safety net for // the following situation: customers upgrading from a version of a2 diff --git a/components/automate-deployment/pkg/manifest/client/http.go b/components/automate-deployment/pkg/manifest/client/http.go index 1b1373a899cc..7cdf31171af2 100644 --- a/components/automate-deployment/pkg/manifest/client/http.go +++ b/components/automate-deployment/pkg/manifest/client/http.go @@ -234,11 +234,7 @@ func (c *HTTP) manifestFromURL(ctx context.Context, url string) (*manifest.A2, e return nil, err } - //Todo(milestone) Append min compatible version needed to upgrade for the current manifest - m.HartOverrides = []habpkg.Hart{} return m, nil } - -//Todo(milestone) method to find min compatible version needed to upgrade. diff --git a/components/automate-deployment/pkg/manifest/provider_test.go b/components/automate-deployment/pkg/manifest/provider_test.go index da8e1ba8ffe5..640b6ac4b010 100644 --- a/components/automate-deployment/pkg/manifest/provider_test.go +++ b/components/automate-deployment/pkg/manifest/provider_test.go @@ -172,25 +172,25 @@ func TestGetCompatibleManifestVersion(t *testing.T) { version: "20220113154113", isMinorAvailable: false, isMajorAvailable: true, - compatibleVersion: "1.2.1", + compatibleVersion: "3.2.1", isError: false, errorString: "", }, { input: "set1", - version: "1.0.0", + version: "3.0.0", isMinorAvailable: true, isMajorAvailable: false, - compatibleVersion: "1.2.1", + compatibleVersion: "3.2.1", isError: false, errorString: "", }, { input: "set1", - version: "1.2.1", + version: "3.2.1", isMinorAvailable: false, isMajorAvailable: true, - compatibleVersion: "2.1.2", + compatibleVersion: "4.1.2", isError: false, errorString: "", }, @@ -199,25 +199,25 @@ func TestGetCompatibleManifestVersion(t *testing.T) { version: "20220113154113", isMinorAvailable: false, isMajorAvailable: true, - compatibleVersion: "1.0.0", + compatibleVersion: "3.0.0", isError: false, errorString: "", }, { input: "set2", - version: "1.0.0", + version: "3.0.0", isMinorAvailable: false, isMajorAvailable: false, - compatibleVersion: "1.0.0", + compatibleVersion: "3.0.0", isError: false, errorString: "", }, { input: "set3", - version: "1.0.0", + version: "3.0.0", isMinorAvailable: false, isMajorAvailable: true, - compatibleVersion: "2.0.0", + compatibleVersion: "4.0.0", isError: false, errorString: "", }, @@ -232,10 +232,10 @@ func TestGetCompatibleManifestVersion(t *testing.T) { }, { input: "set5", - version: "1.0.0", + version: "3.0.0", isMinorAvailable: true, isMajorAvailable: false, - compatibleVersion: "1.2.5", + compatibleVersion: "3.2.5", isError: false, errorString: "", }, @@ -271,8 +271,8 @@ func TestGetMinCurrentVersion(t *testing.T) { }{ { input: "set1", - version: "2.1.2", - compatibleVersion: "1.2.1", + version: "4.1.2", + compatibleVersion: "3.2.1", isError: false, errorString: "", }, @@ -285,21 +285,21 @@ func TestGetMinCurrentVersion(t *testing.T) { }, { input: "set1", - version: "3.4.5", - compatibleVersion: "2.1.2", + version: "5.4.5", + compatibleVersion: "4.1.2", isError: false, errorString: "", }, { input: "set1", - version: "1.0.0", + version: "3.0.0", compatibleVersion: "20220113154113", isError: false, errorString: "", }, { input: "set1", - version: "1.2.1", + version: "3.2.1", compatibleVersion: "20220113154113", isError: false, errorString: "", @@ -313,15 +313,15 @@ func TestGetMinCurrentVersion(t *testing.T) { }, { input: "set2", - version: "1.0.0", + version: "3.0.0", compatibleVersion: "20220113154113", isError: false, errorString: "", }, { input: "set3", - version: "2.0.0", - compatibleVersion: "1.0.0", + version: "4.0.0", + compatibleVersion: "3.0.0", isError: false, errorString: "", }, @@ -334,8 +334,8 @@ func TestGetMinCurrentVersion(t *testing.T) { }, { input: "set5", - version: "1.2.5", - compatibleVersion: "1.0.0", + version: "3.2.5", + compatibleVersion: "3.0.0", isError: false, errorString: "", }, @@ -371,10 +371,10 @@ func TestGetAllVersions(t *testing.T) { } else if param[0] == "set2" { resp = []string{ "20220113154113", - "22.0.0", - "22.2.6", - "23.2.4", - "22.2.16", + "3.0.0", + "3.2.6", + "4.2.4", + "3.2.16", } } @@ -393,7 +393,7 @@ func TestGetAllVersions(t *testing.T) { }, { input: "set2", - output: []string{"20220113154113", "22.0.0", "22.2.6", "22.2.16", "23.2.4"}, + output: []string{"20220113154113", "3.0.0", "3.2.6", "3.2.16", "4.2.4"}, }, } @@ -418,23 +418,23 @@ func compatibleVerServer() *httptest.Server { "20211220104140", "20220113145751", "20220113154113", - "1.0.0", - "1.1.9", - "1.2.1", - "2.0.0", - "2.1.2", - "3.4.5", + "3.0.0", + "3.1.9", + "3.2.1", + "4.0.0", + "4.1.2", + "5.4.5", } } else if param[0] == "set2" { resp = []string{ "20220113154113", - "1.0.0", + "3.0.0", } } else if param[0] == "set3" { resp = []string{ "20220113154113", - "1.0.0", - "2.0.0", + "3.0.0", + "4.0.0", } } else if param[0] == "set4" { resp = []string{ @@ -447,8 +447,8 @@ func compatibleVerServer() *httptest.Server { } } else if param[0] == "set5" { resp = []string{ - "1.0.0", - "1.2.5", + "3.0.0", + "3.2.5", } } bytes, _ := json.Marshal(resp) diff --git a/components/automate-deployment/pkg/server/server.go b/components/automate-deployment/pkg/server/server.go index 9a4b0fdd1426..9c8e0a703f27 100644 --- a/components/automate-deployment/pkg/server/server.go +++ b/components/automate-deployment/pkg/server/server.go @@ -1231,7 +1231,7 @@ func (s *server) nextManifest() (*manifest.A2, error) { return m, nil } - logrus.Infof("Next upgradable manifest on channel %q (%s) is not compatible with current manifest (%s), ignoring", + logrus.Infof("The next available version %s in channel %q requires a manual upgrade with --major flag from the current version %s. Thus, ignoring auto-upgrade", s.deployment.Channel(), nextVersion, s.deployment.CurrentReleaseManifest.Version()) @@ -1855,11 +1855,11 @@ func (s *server) IsValidUpgrade(ctx context.Context, req *api.UpgradeRequest) (* if isMinorAvailable { nextManifestVersion = compVersion } else if isMajorAvailable { - return nil, status.Errorf(codes.InvalidArgument, "please use `chef-automate upgrade run --major` to further upgrade") + return nil, status.Errorf(codes.FailedPrecondition, "This is a Major upgrade. Please use `--major` flag in the above command") } } else { //major upgrade if isMinorAvailable { - return nil, status.Errorf(codes.InvalidArgument, "minor/patch version is available, please use `chef-automate upgrade run`") + return nil, status.Errorf(codes.FailedPrecondition, "The next upgradable version is not a major version upgrade, please run the upgrade command without `--major` flag") } else if isMajorAvailable { nextManifestVersion = compVersion } @@ -1874,26 +1874,26 @@ func (s *server) IsValidUpgrade(ctx context.Context, req *api.UpgradeRequest) (* //compare minimum compatible version with current version, i.e current version should be greater than or equal than min compatible version minCompVersion := m.MinCompatibleVer if minCompVersion == "" { - return nil, status.Error(codes.InvalidArgument, "mandatory minimum compatable version is missing") + return nil, status.Error(codes.FailedPrecondition, "The minimum compatible version field is missing in the manifest, please create a bundle with the latest automate-cli") } else if !isCompatibleForAirgap(currentRelease, minCompVersion) { - return nil, status.Errorf(codes.OutOfRange, "the version specified %q is not compatible for the current version %q. The compatible version is %q", nextManifestVersion, currentRelease, minCompVersion) + return nil, status.Errorf(codes.FailedPrecondition, "The version specified %q is not compatible with the current version %q. Please first upgrade to the minimum compatible version %q", nextManifestVersion, currentRelease, minCompVersion) } //check for upgrade or degrade, we should not allow degrading if isDegrade(currentRelease, nextManifestVersion) { - return nil, status.Errorf(codes.OutOfRange, "the version specified %q is not compatible for the current version %q", nextManifestVersion, currentRelease) + return nil, status.Errorf(codes.InvalidArgument, "The version specified %q is older than the current version %q", nextManifestVersion, currentRelease) } isActualMajorUpgrade := isMajorUpgrade(currentRelease, nextManifestVersion) //check the upgrade is major or not, and if the upgrade is minor/patch, user should not provide --major flag if !isActualMajorUpgrade && req.IsMajorUpgrade { - return nil, status.Errorf(codes.InvalidArgument, "please use `chef-automate upgrade run --airgap-bundle` to further upgrade") + return nil, status.Errorf(codes.FailedPrecondition, "The next upgradable version is not a major version upgrade, please run the upgrade command without `--major` flag") } //check the upgrade is major or not, and if the upgrade is major user should provide --major flag. if isActualMajorUpgrade && !req.IsMajorUpgrade { - return nil, status.Errorf(codes.InvalidArgument, "please use `chef-automate upgrade run --major --airgap-bundle` to further upgrade") + return nil, status.Errorf(codes.FailedPrecondition, "This is a Major upgrade. Please use `--major` flag in the above command") } } @@ -1904,7 +1904,7 @@ func (s *server) IsValidUpgrade(ctx context.Context, req *api.UpgradeRequest) (* } if nextManifestVersion != req.Version && !isCompatible(currentRelease, req.Version, nextManifestVersion) { - return nil, status.Errorf(codes.OutOfRange, "the version specified %q is not compatible for the current version %q", req.Version, currentRelease) + return nil, status.Errorf(codes.InvalidArgument, "The specified version %q is not compatible with the current version %q. The current version can be upgraded to %q", req.Version, currentRelease, nextManifestVersion) } nextManifestVersion = req.Version diff --git a/components/automate-deployment/pkg/server/server_test.go b/components/automate-deployment/pkg/server/server_test.go index 83708a7ac417..5d559fdb4a9d 100644 --- a/components/automate-deployment/pkg/server/server_test.go +++ b/components/automate-deployment/pkg/server/server_test.go @@ -285,91 +285,91 @@ func TestIsCompatible(t *testing.T) { name: "timestampversion,timestampversion,semVersion", currentVersion: "20220110173839", givenVersion: "20220120081508", - maxPossibleVersion: "22.0.0", + maxPossibleVersion: "3.0.0", isCompatible: true, }, { name: "timestampversion,timestampversion,semVersion_fail", currentVersion: "20220120081508", givenVersion: "20220110173839", - maxPossibleVersion: "22.0.0", + maxPossibleVersion: "3.0.0", isCompatible: false, }, { name: "timestampversion,semVersion,timestampversion", currentVersion: "20220110173839", - givenVersion: "22.0.0", + givenVersion: "3.0.0", maxPossibleVersion: "20220120081508", isCompatible: false, }, { name: "timestampversion,semVersion,semVersion", currentVersion: "20220110173839", - givenVersion: "22.0.0", - maxPossibleVersion: "22.0.6", + givenVersion: "3.0.0", + maxPossibleVersion: "3.0.6", isCompatible: true, }, { name: "timestampversion,semVersion,semVersion_equal", currentVersion: "20220110173839", - givenVersion: "22.2.6", - maxPossibleVersion: "22.2.6", + givenVersion: "3.2.6", + maxPossibleVersion: "3.2.6", isCompatible: true, }, { name: "timestampversion,semVersion,semVersion_fail", currentVersion: "20220110173839", - givenVersion: "22.2.6", - maxPossibleVersion: "22.0.0", + givenVersion: "3.2.6", + maxPossibleVersion: "3.0.0", isCompatible: false, }, { name: "semVersion,timestampversion,semVersion", - currentVersion: "22.0.0", + currentVersion: "3.0.0", givenVersion: "20220120081508", - maxPossibleVersion: "22.0.0", + maxPossibleVersion: "3.0.0", isCompatible: false, }, { name: "semVersion,semVersion,semVersion", - currentVersion: "22.0.0", - givenVersion: "22.9.0", - maxPossibleVersion: "22.12.0", + currentVersion: "3.0.0", + givenVersion: "3.9.0", + maxPossibleVersion: "3.12.0", isCompatible: true, }, { name: "semVersion,semVersion,semVersion_equal", - currentVersion: "22.0.0", - givenVersion: "22.0.0", - maxPossibleVersion: "22.0.0", + currentVersion: "3.0.0", + givenVersion: "3.0.0", + maxPossibleVersion: "3.0.0", isCompatible: true, }, { name: "semVersion,semVersion,semVersion_fail_back_minor", - currentVersion: "22.4.0", - givenVersion: "22.2.0", - maxPossibleVersion: "23.4.0", + currentVersion: "3.4.0", + givenVersion: "3.2.0", + maxPossibleVersion: "3.4.0", isCompatible: false, }, { name: "semVersion,semVersion,semVersion_fail_major", - currentVersion: "22.0.0", - givenVersion: "22.5.0", - maxPossibleVersion: "23.0.0", + currentVersion: "3.0.0", + givenVersion: "3.5.0", + maxPossibleVersion: "4.0.0", isCompatible: false, }, { name: "semVersion,semVersion,semVersion_fail_minor", - currentVersion: "22.0.0", - givenVersion: "22.4.0", - maxPossibleVersion: "22.3.0", + currentVersion: "3.0.0", + givenVersion: "3.4.0", + maxPossibleVersion: "3.3.0", isCompatible: false, }, { name: "semVersion,semVersion,semVersion_fail_patch", - currentVersion: "22.0.0", - givenVersion: "22.4.10", - maxPossibleVersion: "22.4.8", + currentVersion: "3.0.0", + givenVersion: "3.4.10", + maxPossibleVersion: "3.4.8", isCompatible: false, }, } @@ -413,31 +413,31 @@ func TestIsCompatibleForConverge(t *testing.T) { { name: "timestamp,semversion", currentVersion: "20220110173839", - nextVersion: "22.3.5", + nextVersion: "3.3.5", isCompatible: false, }, { name: "semversion,timestamp", - currentVersion: "22.3.5", + currentVersion: "3.3.5", nextVersion: "20220110173839", isCompatible: false, }, { name: "semversion,semversion_same_major_valid", - currentVersion: "22.3.5", - nextVersion: "22.3.12", + currentVersion: "3.3.5", + nextVersion: "3.3.12", isCompatible: true, }, { name: "semversion,semversion_same_major_invalid", - currentVersion: "22.3.12", - nextVersion: "22.3.5", + currentVersion: "3.3.12", + nextVersion: "3.3.5", isCompatible: false, }, { name: "semversion,semversion_different_major", - currentVersion: "22.3.12", - nextVersion: "24.0.0", + currentVersion: "3.3.12", + nextVersion: "5.0.0", isCompatible: false, }, } @@ -478,49 +478,49 @@ func TestIsCompatibleForAirgap(t *testing.T) { { name: "timestampversion,semanticversion", currentVersion: "20220112175624", - minCompatibleVer: "22.0.1", + minCompatibleVer: "3.0.1", isCompatible: false, }, { name: "semanticversion,timestampversion", - currentVersion: "22.0.1", + currentVersion: "3.0.1", minCompatibleVer: "20220112175624", isCompatible: true, }, { name: "semanticversion,semanticversion", - currentVersion: "22.0.1", - minCompatibleVer: "22.0.0", + currentVersion: "3.0.1", + minCompatibleVer: "3.0.0", isCompatible: true, }, { name: "semanticversion,semanticversion_success", - currentVersion: "23.12.14", - minCompatibleVer: "22.10.14", + currentVersion: "4.12.14", + minCompatibleVer: "3.10.14", isCompatible: true, }, { name: "semanticversion,semanticversion_success_1", - currentVersion: "22.10.14", - minCompatibleVer: "22.9.14", + currentVersion: "3.10.14", + minCompatibleVer: "3.9.14", isCompatible: true, }, { name: "semanticversion,semanticversion_success_2", - currentVersion: "22.10.14", - minCompatibleVer: "22.10.8", + currentVersion: "3.10.14", + minCompatibleVer: "3.10.8", isCompatible: true, }, { name: "semanticversion,semanticversion_fail", - currentVersion: "22.10.14", - minCompatibleVer: "23.12.14", + currentVersion: "3.10.14", + minCompatibleVer: "4.12.14", isCompatible: false, }, { name: "semanticversion,semanticversion_fail_1", - currentVersion: "22.10.9", - minCompatibleVer: "22.10.15", + currentVersion: "3.10.9", + minCompatibleVer: "3.10.15", isCompatible: false, }, } @@ -560,55 +560,55 @@ func TestIsDegrade(t *testing.T) { { name: "timestamp,semantic_fail", v1: "20220110000000", - v2: "22.0.1", + v2: "3.0.1", isDegrade: false, }, { name: "semantic,timestamp", - v1: "22.0.1", + v1: "3.0.1", v2: "20220110000000", isDegrade: true, }, { name: "semantic,semantic_patch", - v1: "22.4.10", - v2: "22.4.9", + v1: "3.4.10", + v2: "3.4.9", isDegrade: true, }, { name: "semantic,semantic_patch_fail", - v1: "22.4.9", - v2: "22.4.10", + v1: "3.4.9", + v2: "3.4.10", isDegrade: false, }, { name: "semantic,semantic_minor", - v1: "22.4.10", - v2: "22.3.10", + v1: "3.4.10", + v2: "3.3.10", isDegrade: true, }, { name: "semantic,semantic_minor_fail", - v1: "22.3.10", - v2: "22.4.10", + v1: "3.3.10", + v2: "3.4.10", isDegrade: false, }, { name: "semantic,semantic_major", v1: "23.3.10", - v2: "22.3.10", + v2: "3.3.10", isDegrade: true, }, { name: "semantic,semantic_major_fail", - v1: "22.3.10", - v2: "23.3.10", + v1: "3.3.10", + v2: "4.3.10", isDegrade: false, }, { name: "semantic,semantic_major_equal", - v1: "22.3.10", - v2: "22.3.10", + v1: "3.3.10", + v2: "3.3.10", isDegrade: false, }, } @@ -636,25 +636,25 @@ func TestIsMajorUpgrade(t *testing.T) { { name: "timestamp,semantic", v1: "20220110000000", - v2: "21.2.0", + v2: "3.2.0", isMajorUpgrade: true, }, { name: "semantic,timestamp", - v1: "21.2.0", + v1: "3.2.0", v2: "20220110000000", isMajorUpgrade: false, }, { name: "semantic,semantic_success", - v1: "21.2.0", - v2: "22.10.0", + v1: "3.2.0", + v2: "4.10.0", isMajorUpgrade: true, }, { name: "semantic,semantic_fail", - v1: "21.2.0", - v2: "21.8.0", + v1: "3.2.0", + v2: "3.8.0", isMajorUpgrade: false, }, } diff --git a/components/automate-deployment/pkg/server/upgrade_status.go b/components/automate-deployment/pkg/server/upgrade_status.go index 927888e48ad8..bac20999aaed 100644 --- a/components/automate-deployment/pkg/server/upgrade_status.go +++ b/components/automate-deployment/pkg/server/upgrade_status.go @@ -144,7 +144,6 @@ func detectUpgradingServices(a2Manifest *manifest.A2, // // Our standard data format of YYYYMMDDHHMMSS // is lexicographically sortable. - //Todo(milestone) recheck the below comparison logic for semantic versioning format if svc.Pkg.Release < deploymentService.Release() { upgradingService := makeUpgradingService(&svc, deploymentService) ret = append(ret, upgradingService)