Skip to content

Conversation

shwstppr
Copy link
Contributor

@shwstppr shwstppr commented Sep 8, 2025

Description

Fixes #9477

This PR unlinks all userdata entities which are deleted as part of account cleanup.

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?

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

Copy link

codecov bot commented Sep 8, 2025

Codecov Report

❌ Patch coverage is 2.70270% with 36 lines in your changes missing coverage. Please review.
✅ Project coverage is 17.35%. Comparing base (3ddd802) to head (3a31c16).
⚠️ Report is 2 commits behind head on main.

Files with missing lines Patch % Lines
.../main/java/com/cloud/user/dao/UserDataDaoImpl.java 0.00% 16 Missing ⚠️
.../java/com/cloud/storage/dao/VMTemplateDaoImpl.java 0.00% 13 Missing ⚠️
...n/java/com/cloud/template/TemplateManagerImpl.java 0.00% 7 Missing ⚠️
Additional details and impacted files
@@             Coverage Diff              @@
##               main   #11595      +/-   ##
============================================
- Coverage     17.36%   17.35%   -0.01%     
- Complexity    15235    15236       +1     
============================================
  Files          5888     5888              
  Lines        525740   525775      +35     
  Branches      64164    64165       +1     
============================================
- Hits          91272    91267       -5     
- Misses       424168   424208      +40     
  Partials      10300    10300              
Flag Coverage Δ
uitests 3.63% <ø> (ø)
unittests 18.39% <2.70%> (-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 shwstppr force-pushed the acc-userdata-unlink branch from 7acde42 to 3a31c16 Compare September 9, 2025 10:17
@shwstppr
Copy link
Contributor Author

shwstppr commented Sep 9, 2025

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

@blueorangutan
Copy link

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

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.

@shwstppr I believe this fix will not effect the VMs that are already created using the template which previously linked to the userdata as we are saving the actual userdata in user_vm table. am I right ?

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.

Deleted userdata owned by a deleted account remains linked with the template
3 participants