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

   ### Description
   
   When deploying a VM is failed during the allocation process it may leave the 
resources that have been already allocated before the failure. They will get 
removed from the database as the whole code block is wrapped inside a 
transaction twice but the server would not inform the network or storage 
plugins to clean up the allocated resources. This PR removes Transactions 
during VM allocation which results in the allocated VM and its resource records 
being persisted in DB even during failures. When failure is encountered VM is 
moved to Error state. This helps VM and its resources to be properly 
deallocated when it is expunged either by a server task such as ExpungeTask or 
during manual expunge.
   
   ### 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)
   
   ### 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?
   <!-- Please describe in detail how you tested your changes. -->
   <!-- Include details of your testing environment, and the tests you ran to 
-->
   <!-- see how your change affects other areas of the code, etc. -->
   
   
   <!-- Please read the 
[CONTRIBUTING](https://github.com/apache/cloudstack/blob/main/CONTRIBUTING.md) 
document -->
   


-- 
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