-
Notifications
You must be signed in to change notification settings - Fork 1.1k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Fix deploy as is VM start after template deletion #8115
Fix deploy as is VM start after template deletion #8115
Conversation
ed972a7
to
4a78277
Compare
@blueorangutan package |
@harikrishna-patnala a [SF] 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. |
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.
code lgtm
I am fine with this change, although this will lead to some records in the database.
I think this is safest way to do, unless we can 100% figure out what details needs to be kept after template is removed.
We probably need to look into the template details as well
// Remove template details
templateDetailsDao.removeDetails(template.getId());
I think the best way is to copy template details to the ivm_instance_details on deploy |
@DaanHoogland |
yes, but that would solve the DB remnance. I am not demanding we change this, just suggesting what could be a better design choice. |
template_deploy_as_is_details looks like this The corresponding values in user_vm_deploy_as_is_details looks like this So I dont think we can directly copy the template_deploy_as_is_details to user_vm_deploy_as_is_details as it is. Currently we are parsing everything from user_vm_deploy_as_is_details table and passing them to the resource. To simplify all these, I thought it will be better to keep the template_deploy_as_is_details even after deletion. |
7e0ba1e
to
ebf01da
Compare
@blueorangutan package |
@harikrishna-patnala 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. |
Packaging result [SF]: ✔️ el7 ✔️ el8 ✔️ el9 ✔️ debian ✔️ suse15. SL-JID 7443 |
Codecov Report
@@ Coverage Diff @@
## 4.18 #8115 +/- ##
============================================
+ Coverage 13.02% 13.06% +0.04%
- Complexity 9032 9108 +76
============================================
Files 2720 2720
Lines 257080 257547 +467
Branches 40088 40152 +64
============================================
+ Hits 33476 33655 +179
- Misses 219400 219664 +264
- Partials 4204 4228 +24
... and 8 files with indirect coverage changes 📣 We’re building smart automated test selection to slash your CI/CD build times. Learn more |
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.
some style critique but clgtm
server/src/main/java/com/cloud/template/HypervisorTemplateAdapter.java
Outdated
Show resolved
Hide resolved
server/src/main/java/com/cloud/template/HypervisorTemplateAdapter.java
Outdated
Show resolved
Hide resolved
@blueorangutan test |
@DaanHoogland a [SL] Trillian-Jenkins test job (centos7 mgmt + kvm-centos7) has been kicked to run smoke tests |
[SF] Trillian test result (tid-8040)
|
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.
Code LGTM
@harikrishna-patnala are you making any more changes for review comments? |
@blueorangutan package |
@harikrishna-patnala 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. |
@blueorangutan package |
@rohityadavcloud 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. |
@blueorangutan test rocky8 xenserver-71 |
@DaanHoogland a [SL] Trillian-Jenkins test job (rocky8 mgmt + xenserver-71) has been kicked to run smoke tests |
@blueorangutan test alma9 vmware-70u3 |
@DaanHoogland a [SL] Trillian-Jenkins test job (alma9 mgmt + vmware-70u3) has been kicked to run smoke tests |
[SF] Trillian test result (tid-8148)
|
[SF] Trillian Build Failed (tid-8277) |
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.
LGTM. Instance starts fine with this fix although the template (vAPP) is deleted, it was failing earlier. Also observed is that the data is retained in the table template_deploy_as_is_details
even after the template deletion as required by this fix. As mentioned already here this has side effects.
@blueorangutan package |
@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. |
Packaging result [SF]: ✖️ el7 ✖️ el8 ✖️ el9 ✖️ debian ✖️ suse15. SL-JID 7702 |
@blueorangutan package |
@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. |
Packaging result [SF]: ✔️ el7 ✔️ el8 ✔️ el9 ✔️ debian ✔️ suse15. SL-JID 7719 |
@blueorangutan test alma9 vmware-70u3 |
@DaanHoogland a [SL] Trillian-Jenkins test job (alma9 mgmt + vmware-70u3) has been kicked to run smoke tests |
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.
code lgtm
[SF] Trillian test result (tid-8308)
|
can this PR be merged, I see the above failures on other PRs also |
yes, we shouldn't ignore them, but I am going through them and will add any cleanup or added robustness in #8196 |
* 4.18: Fix deploy as is VM start after template deletion (#8115)
* 4.18: Fix deploy as is VM start after template deletion (apache#8115)
Description
This PR fixes the issue #7970
Fix is to keep the template deploy as is details even after the template is deleted. VM start need to know whether the vapp property is password or not which are saved in template_deploy_as_is_details table.
Types of changes
Bug Severity
How Has This Been Tested?