Dogface2k opened a new pull request, #13753:
URL: https://github.com/apache/cloudstack/pull/13753

   ### Description
   
   This PR prevents VMware NSX-backed guest network implementation from failing 
when vCenter has not yet exposed the backing distributed virtual port group 
immediately after NSX segment creation.
   
   The NSX branch in `HypervisorHostHelper.prepareNetwork` now uses the 
existing bounded `waitForDvPortGroupReady` path. The change does not retry the 
CloudStack mutation or create a second network; it only waits for vCenter 
inventory visibility before returning the already-created port group.
   
   A regression test simulates an empty first vCenter lookup followed by the 
port group becoming available. The existing immediate-availability behavior 
remains covered.
   
   Fixes: #13752
   
   ### Types of changes
   
   - [ ] Breaking change (fix or feature that would cause existing 
functionality to change)
   - [ ] New feature (non-breaking change which adds functionality)
   - [x] 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
   - [x] Major
   - [ ] Minor
   - [ ] Trivial
   
   ### Screenshots (if appropriate):
   
   Not applicable.
   
   ### How Has This Been Tested?
   
   Targeted regression and baseline tests were run on the `4.22` branch with 
Java 17:
   
   ```text
   HypervisorHostHelperTest#testPrepareNetwork
   HypervisorHostHelperTest#testPrepareNetworkWaitsForNsxDvPortGroup
   
   Tests run: 2, Failures: 0, Errors: 0, Skipped: 0
   ```
   
   The Maven reactor built all 18 required modules successfully, including 
`cloud-vmware-base`, with zero Checkstyle violations.
   
   ### How did you try to break this feature and the system with this change?
   
   The regression test makes the first vCenter DV port group query return no 
result and the second return the expected port group. The pre-existing 
immediate-availability test also runs to verify the normal fast path remains 
unchanged. The production path remains bounded by the existing readiness 
timeout and returns failure if the port group never appears.
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to