Created attachment 1493019 [details] screenshot from report output Description of problem: The Retirement Requester field is not being populated in the db Version-Release number of selected component (if applicable): 5.9.4.7 How reproducible: Always Steps to Reproduce: 1. Retire a vm 2. check db for retirement_requester (note the field is blank) vmdb_production=# select name, retirement_requester, retirement_state, updated_on, retires_on from vms where retirement_state='retired'; Actual results: retirement_requester field is blank Expected results: retirement_requester field should be populated with an identifier of the user/account that retired the vm Additional info: Customer's environment: vmdb_production=# select id,name,retirement_requester from vms where name = 'rovalent-retire-test-1'; id | name | retirement_requester -----+------------------------+---------------------- 255 | rovalent-retire-test-1 | (1 row) Test machine: vmdb_production=# select name, retirement_requester, retirement_state, updated_on, retires_on from vms where retirement_state='retired'; name | retirement_requester | retirement_state | updated_on | retires_on ---------------+----------------------+------------------+----------------------------+---------------------------- joshpitney | | retired | 2018-10-11 14:09:12.504495 | 2018-10-11 14:09:12.495141 tuanpitney2 | | retired | 2018-10-11 14:10:55.165838 | 2018-10-11 14:10:55.157481 joshpitney | | retired | 2018-10-11 14:08:45.957654 | 2018-10-11 14:08:45.949449 tuanpitney | | retired | 2018-10-11 14:10:16.275354 | 2018-10-11 14:10:16.265689 yoderpitney | | retired | 2018-10-11 14:11:21.554975 | 2018-10-11 14:11:21.545749 change_me0002 | | retired | 2018-10-11 14:11:44.081028 | 2018-10-11 14:11:44.063414 change_me0001 | | retired | 2018-10-11 14:08:09.968484 | 2018-10-11 14:08:09.961166 davidpitney | | retired | 2018-10-11 14:08:50.666189 | 2018-10-11 14:08:50.656435 (8 rows)
I know this is for 5.9, but could you please retest it on latest dev env (not an appliance, I don't know when anything will get built that includes those changes)? There's a change that got in here: https://github.com/ManageIQ/manageiq/pull/17951 that should have fixed this.
Drew, Retested on Hammer, retirement_requester field is still blank.
https://github.com/ManageIQ/manageiq/pull/18113
https://github.com/ManageIQ/manageiq/pull/18117
These've both been merged so I'm moving this to post. I'll need to have this cloned, and different PRs for that, since the code is drastically different for these versions...
New commit detected on ManageIQ/manageiq/hammer: https://github.com/ManageIQ/manageiq/commit/c7715ec2ef78f24933420868fa2c1dc2fb2e4711 commit c7715ec2ef78f24933420868fa2c1dc2fb2e4711 Author: Keenan Brock <keenan> AuthorDate: Mon Oct 22 14:39:22 2018 -0400 Commit: Keenan Brock <keenan> CommitDate: Mon Oct 22 14:39:22 2018 -0400 Merge pull request #18113 from d-m-u/adding_object_retirement_requester Add object retirement_requester (cherry picked from commit aaf424f04def8ce40be7e639730782c9f8f38042) https://bugzilla.redhat.com/show_bug.cgi?id=1638502 app/models/mixins/retirement_mixin.rb | 11 + spec/models/orchestration_stack/retirement_management_spec.rb | 1 + spec/models/service/retirement_management_spec.rb | 13 +- spec/models/vm/retirement_management_spec.rb | 10 +- 4 files changed, 25 insertions(+), 10 deletions(-) https://github.com/ManageIQ/manageiq/commit/4c11b0d164b08aa881dea893cb0dd7733895b991 commit 4c11b0d164b08aa881dea893cb0dd7733895b991 Author: Keenan Brock <keenan> AuthorDate: Mon Oct 22 15:43:24 2018 -0400 Commit: Keenan Brock <keenan> CommitDate: Mon Oct 22 15:43:24 2018 -0400 Merge pull request #18117 from d-m-u/fixing_red_master Don't need the name, since it's mixed in... (cherry picked from commit 1544ad2adc38c985d0af2db283a92f88c0310cde) https://bugzilla.redhat.com/show_bug.cgi?id=1638502 app/models/mixins/retirement_mixin.rb | 10 +- 1 file changed, 5 insertions(+), 5 deletions(-)
Created attachment 1508829 [details] DB OUTPUT on 5.10.0.25
Created attachment 1508830 [details] VM Retire Report YAML
https://github.com/ManageIQ/manageiq/pull/18242
Please ignore comment 13, it's wrong.
https://github.com/ManageIQ/manageiq/pull/18325
Hi Marianne, Drew created a PR for this issue, and it's currently under review. We feel good about getting it merged before the build next week, and will update the ticket with our test results. Thanks, Tina
FIXED. Verified on 5.10.0.31.20190108221820_a0968c8. Retirement requester appears in both reports and database query even after the VM has retired.
Since the problem described in this bug report should be resolved in a recent advisory, it has been closed with a resolution of ERRATA. For information on the advisory, and where to find the updated files, follow the link below. If the solution does not work for you, open a new bug report. https://access.redhat.com/errata/RHSA-2019:0212