Bug 1678476 - system_context requester for retirement returns RecordNotFound if evm_owner_id points to user that's been deleted
Summary: system_context requester for retirement returns RecordNotFound if evm_owner_i...
Alias: None
Product: Red Hat CloudForms Management Engine
Classification: Red Hat
Component: Automate
Version: 5.10.0
Hardware: Unspecified
OS: Unspecified
Target Milestone: GA
: 5.10.4
Assignee: drew uhlmann
QA Contact: Niyaz Akhtar Ansari
Red Hat CloudForms Documentation
: 1678474 (view as bug list)
Depends On: 1673143
TreeView+ depends on / blocked
Reported: 2019-02-18 21:02 UTC by Satoe Imaishi
Modified: 2019-05-21 05:47 UTC (History)
9 users (show)

Fixed In Version:
Doc Type: If docs needed, set a value
Doc Text:
Clone Of: 1673143
Last Closed: 2019-05-21 05:46:54 UTC
Category: ---
Cloudforms Team: CFME Core
Target Upstream Version:

Attachments (Terms of Use)

System ID Priority Status Summary Last Updated
Red Hat Product Errata RHBA-2019:1247 None None None 2019-05-21 05:47:01 UTC

Comment 1 CFME Bot 2019-02-18 21:15:37 UTC
New commits detected on ManageIQ/manageiq/hammer:

commit 2aa3228428546cfd16f4d67319fb5aac01b7d25e
Author:     Greg McCullough <gmccullo@redhat.com>
AuthorDate: Mon Feb 11 12:04:57 2019 -0500
Commit:     Greg McCullough <gmccullo@redhat.com>
CommitDate: Mon Feb 11 12:04:57 2019 -0500

    Merge pull request #18443 from d-m-u/remove_lbs_from_retirement_check

    Don't retire load balancers

    (cherry picked from commit d8a6ba00be00d215a44af0f71e27f7ad364967ba)


 app/models/load_balancer.rb | 1 -
 app/models/retirement_manager.rb | 2 +-
 spec/models/retirement_manager_spec.rb | 4 +-
 3 files changed, 2 insertions(+), 5 deletions(-)

commit 65aa7d015bb1d6782b1ca8c5908d21980c33bc92
Author:     Brandon Dunne <brandondunne@hotmail.com>
AuthorDate: Mon Feb 18 15:38:18 2019 -0500
Commit:     Brandon Dunne <brandondunne@hotmail.com>
CommitDate: Mon Feb 18 15:38:18 2019 -0500

    Merge pull request #18437 from d-m-u/adding_user_existence_check

    Add check for existence of user for system_context

    (cherry picked from commit 265774dd3ab68ae26f117e2cca073003cb5066d3)

    Fixes https://bugzilla.redhat.com/show_bug.cgi?id=1678476

 app/models/mixins/retirement_mixin.rb | 10 +-
 spec/models/orchestration_stack/retirement_management_spec.rb | 43 +-
 spec/models/service/retirement_management_spec.rb | 63 +-
 spec/models/vm/retirement_management_spec.rb | 46 +-
 4 files changed, 107 insertions(+), 55 deletions(-)

Comment 2 Satoe Imaishi 2019-02-18 21:16:59 UTC
*** Bug 1678474 has been marked as a duplicate of this bug. ***

Comment 3 Satoe Imaishi 2019-02-19 15:12:50 UTC
Reverted the backport of https://github.com/ManageIQ/manageiq/pull/18443 and https://github.com/ManageIQ/manageiq/pull/18437

Comment 4 drew uhlmann 2019-02-25 16:40:06 UTC

Comment 5 drew uhlmann 2019-03-28 12:30:23 UTC
Hey you wonderful people, I can't close this bug because the PR in comment 4 hasn't been merged. It'd be super great to get the target release set and get this puppy merged cause it's a couple months old now and I'd really like to close this ticket.

Comment 7 drew uhlmann 2019-04-10 12:29:47 UTC
Hey Gellert, I get that this ticket is associated with the one about the valid retirement date (https://bugzilla.redhat.com/show_bug.cgi?id=1697524) because they both involve the same error, but I think that comment 6 should be on the other ticket since this isn't about a retirement date at all. I think the other bug probably needs the PR that fixes this and it will then need to be retested to make sure there's nothing else wrong with it.

Comment 10 drew uhlmann 2019-04-29 19:59:11 UTC
create a service with a user that isn't admin
provision the service
delete the user from the db
schedule the service to retire more than fifteen minutes from now
check to see who the requester for the retirement shows up as

Comment 13 errata-xmlrpc 2019-05-21 05:46:54 UTC
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.


Note You need to log in before you can comment on or make changes to this bug.