You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
[Investigation] Templates/ISOs are not removed but marked as Inactive #4470
Probably not an issue, but worth investigating the reason why templates/ISOs are not deleted in database (the removed column stays NULL) after deleting a template/ISO. The ticket is raised after some doubts on the reviews of PR #4047
ISSUE TYPE
Other
COMPONENT NAME
API, templates, ISOs
CLOUDSTACK VERSION
All versions
CONFIGURATION
N/A
OS / ENVIRONMENT
N/A
SUMMARY
Deleting a template/ISO does not actually remove it, but set it to Inactive and hidden
STEPS TO REPRODUCE
Remove a template/ISO
EXPECTED RESULTS
Template/ISO removed in database
ACTUAL RESULTS
Template/ISO state = 'Inactive' but removed column not changed
I'm not sure what the original problem was, I have traced the active/inactive fields to a commit in 2013. In the git log there is speak of some kind of problem that was solved from version 2.1.x to do with the removed column not being correctly used.
Fixed the problem with offerings and templates. These two items due to a previous patch all the way back in 2.1.x versions uses the removed column incorrectly. No one fixed since then. Hence, there's a bunch of findbyidincludingremoved calls in the cloudstack code around these two items.
abbae2aa Alex Huang <alex.huang@citrix.com> on 2013/08/27 at 02:30
ok, this means we'll have to look for those find including removed calls and try to make sure the removed column is correctly filled at the correct moment. (future version for now)
Activity
yadvr commentedon Nov 18, 2020
Cc @Spaceman1984 looks like GC issue, have you seen this or can you discuss with @nvazquez and investigate/fix?
Spaceman1984 commentedon Nov 19, 2020
I'll take a look @rhtyd
Spaceman1984 commentedon Nov 23, 2020
I'm not sure what the original problem was, I have traced the active/inactive fields to a commit in 2013. In the git log there is speak of some kind of problem that was solved from version 2.1.x to do with the removed column not being correctly used.
DaanHoogland commentedon Nov 25, 2020
ok, this means we'll have to look for those find including removed calls and try to make sure the removed column is correctly filled at the correct moment. (future version for now)
yadvr commentedon Apr 22, 2021
Looks liked fixed in #4748
@nvazquez can you check?
nvazquez commentedon Apr 22, 2021
Tested - fixed confirmed. Thanks @Pearl1594 @rhtyd