Skip to content

Conversation

@shwstppr
Copy link
Contributor

@shwstppr shwstppr commented Nov 27, 2025

Description

Fixes #12137

Types of changes

  • Breaking change (fix or feature that would cause existing functionality to change)
  • New feature (non-breaking change which adds functionality)
  • Bug fix (non-breaking change which fixes an issue)
  • Enhancement (improves an existing feature and functionality)
  • Cleanup (Code refactoring and cleanup, that may add test cases)
  • Build/CI
  • Test (unit or integration test code)

Feature/Enhancement Scale or Bug Severity

Feature/Enhancement Scale

  • Major
  • Minor

Bug Severity

  • BLOCKER
  • Critical
  • Major
  • Minor
  • Trivial

Screenshots (if appropriate):

How Has This Been Tested?

In a 2 MS environment, stopped one of the server and tried to remove that

(localcloud) 🐱 > list managementservers filter=id,name,state
{
  "count": 2,
  "managementserver": [
    {
      "id": "4737741d-c7b4-421c-a04d-dd2f0e2cd720",
      "name": "pr12151-t14874-kvm-ol8-mgmt1.sofia.shapeblue.com",
      "state": "Up"
    },
    {
      "id": "6995c1f6-943e-42d8-a430-b6933992ec3a",
      "name": "pr12151-t14874-kvm-ol8-mgmt2.sofia.shapeblue.com",
      "state": "Up"
    }
  ]
}
(localcloud) 🐱 > remove managementserver id=6995c1f6-943e-42d8-a430-b6933992ec3a 
🙈 Error: (HTTP 431, error code 4350) Unable to remove Management Server with ID [6995c1f6-943e-42d8-a430-b6933992ec3a]. It can only be removed when it is in the [Down] state, however currently it is in the [Up] state.
(localcloud) 🐱 > list managementservers filter=id,name,state
{
  "count": 2,
  "managementserver": [
    {
      "id": "4737741d-c7b4-421c-a04d-dd2f0e2cd720",
      "name": "pr12151-t14874-kvm-ol8-mgmt1.sofia.shapeblue.com",
      "state": "Up"
    },
    {
      "id": "6995c1f6-943e-42d8-a430-b6933992ec3a",
      "name": "pr12151-t14874-kvm-ol8-mgmt2.sofia.shapeblue.com",
      "state": "Down"
    }
  ]
}
(localcloud) 🐱 > remove managementserver id=6995c1f6-943e-42d8-a430-b6933992ec3a 
{
  "success": true
}

How did you try to break this feature and the system with this change?

Fixes apache#12137

Signed-off-by: Abhishek Kumar <abhishek.mrt22@gmail.com>
@codecov
Copy link

codecov bot commented Nov 27, 2025

Codecov Report

❌ Patch coverage is 0% with 1 line in your changes missing coverage. Please review.
✅ Project coverage is 17.56%. Comparing base (671d8ad) to head (896e321).
⚠️ Report is 117 commits behind head on 4.22.

Files with missing lines Patch % Lines
...in/java/com/cloud/server/ManagementServerImpl.java 0.00% 1 Missing ⚠️
Additional details and impacted files
@@            Coverage Diff            @@
##               4.22   #12147   +/-   ##
=========================================
  Coverage     17.55%   17.56%           
- Complexity    15536    15546   +10     
=========================================
  Files          5909     5910    +1     
  Lines        529118   529123    +5     
  Branches      64627    64627           
=========================================
+ Hits          92902    92934   +32     
+ Misses       425761   425735   -26     
+ Partials      10455    10454    -1     
Flag Coverage Δ
uitests 3.58% <ø> (+<0.01%) ⬆️
unittests 18.63% <0.00%> (+<0.01%) ⬆️

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

@shwstppr
Copy link
Contributor Author

@blueorangutan package

@blueorangutan
Copy link

@shwstppr a [SL] Jenkins job has been kicked to build packages. It will be bundled with KVM, XenServer and VMware SystemVM templates. I'll keep you posted as I make progress.

@shwstppr shwstppr linked an issue Nov 27, 2025 that may be closed by this pull request
@blueorangutan
Copy link

Packaging result [SF]: ✔️ el8 ✔️ el9 ✔️ el10 ✔️ debian ✔️ suse15. SL-JID 15837

@DaanHoogland DaanHoogland added this to the 4.22.1 milestone Nov 27, 2025
@shwstppr shwstppr marked this pull request as ready for review November 28, 2025 09:02
Copy link
Contributor

@DaanHoogland DaanHoogland left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

this slipped through the regression test nets I think, clgtm

@DaanHoogland
Copy link
Contributor

@blueorangutan test

@blueorangutan
Copy link

@DaanHoogland a [SL] Trillian-Jenkins test job (ol8 mgmt + kvm-ol8) has been kicked to run smoke tests

@blueorangutan
Copy link

[SF] Trillian test result (tid-14902)
Environment: kvm-ol8 (x2), zone: Advanced Networking with Mgmt server ol8
Total time taken: 51230 seconds
Marvin logs: https://github.com/blueorangutan/acs-prs/releases/download/trillian/pr12147-t14902-kvm-ol8.zip
Smoke tests completed. 149 look OK, 0 have errors, 0 did not run
Only failed and skipped tests results shown below:

Test Result Time (s) Test File

@DaanHoogland
Copy link
Contributor

@nicoschmdt , can you please review?

Copy link
Contributor

@harikrishna-patnala harikrishna-patnala left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

code LGTM

@harikrishna-patnala harikrishna-patnala merged commit 5fd5b62 into apache:4.22 Jan 27, 2026
40 of 42 checks passed
@harikrishna-patnala harikrishna-patnala deleted the fix-removemgmtsvr branch January 27, 2026 09:31
@blueorangutan
Copy link

[SF] Trillian Build Failed (tid-15296)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

Status: In Progress

Development

Successfully merging this pull request may close these issues.

Remove managmentserver fails

4 participants