Bug 1303872

Summary: The control engine is not detecting "VM Retirement Warn" event.
Product: Red Hat CloudForms Management Engine Reporter: Prasad Mukhedkar <pmukhedk>
Component: ControlAssignee: Lucy Fu <lufu>
Status: CLOSED ERRATA QA Contact: Dmitry Misharov <dmisharo>
Severity: high Docs Contact:
Priority: high    
Version: 5.4.0CC: cpelland, dajohnso, gmccullo, jhardy, jprause, lufu, mfeifer, nachandr, obarenbo, pmukhedk, psavage, ssainkar
Target Milestone: GAKeywords: ZStream
Target Release: 5.4.5   
Hardware: x86_64   
OS: Linux   
Whiteboard: control:retirement
Fixed In Version: 5.4.5.2 Doc Type: Bug Fix
Doc Text:
Previously, "VM Retirement Warn" event was not being detected by the control engine. As a result, the event was unable to be used to trigger the needed action. This patch raised event vm_retire_warn to policy allowing it to now use event to trigger actions in policy.
Story Points: ---
Clone Of: Environment:
Last Closed: 2016-03-29 14:17:38 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:

Comment 5 Greg McCullough 2016-02-02 15:05:19 UTC
Lucy - Can you look into this issue and either Tina or I can help with the vm retirement side, if needed.  Should be easy enough to force this to run for a VM and reset to re-run on the same VM for testing if needed.

Comment 12 CFME Bot 2016-02-09 23:34:16 UTC
New commit detected on cfme/5.4.z:
https://code.engineering.redhat.com/gerrit/gitweb?p=cfme.git;a=commitdiff;h=bfd927f25e0124ae2ca2ca817dfde560389ec86e

commit bfd927f25e0124ae2ca2ca817dfde560389ec86e
Author:     Lucy Fu <lufu>
AuthorDate: Wed Feb 3 12:26:41 2016 -0500
Commit:     Lucy Fu <lufu>
CommitDate: Tue Feb 9 13:58:54 2016 -0500

    Raise vm_retire_warn to policy.
    
    This issue happens only with 5.4.z, before the event switchboard change.
    https://bugzilla.redhat.com/show_bug.cgi?id=1303872

 vmdb/app/models/mixins/retirement_mixin.rb       |  1 +
 vmdb/spec/models/mixins/retirement_mixin_spec.rb | 30 ++++++++++++++++++++++++
 2 files changed, 31 insertions(+)
 create mode 100644 vmdb/spec/models/mixins/retirement_mixin_spec.rb

Comment 13 CFME Bot 2016-02-09 23:34:21 UTC
New commit detected on cfme/5.4.z:
https://code.engineering.redhat.com/gerrit/gitweb?p=cfme.git;a=commitdiff;h=b7fbbc0f0a3bc74b3dcfe31a249d05d09682878b

commit b7fbbc0f0a3bc74b3dcfe31a249d05d09682878b
Merge: 9372e7c bfd927f
Author:     Greg McCullough <gmccullo>
AuthorDate: Tue Feb 9 18:25:51 2016 -0500
Commit:     Greg McCullough <gmccullo>
CommitDate: Tue Feb 9 18:25:51 2016 -0500

    Merge branch '5.4.z-raise_vm_retirment_event_to_policy_1303872' into '5.4.z'
    
    Raise event vm_retire_warn to policy.
    
    This issue happens only with 5.4.z, before the Event Switchboard change.
    
    https://bugzilla.redhat.com/show_bug.cgi?id=1303872
    
    See merge request !768

 vmdb/app/models/mixins/retirement_mixin.rb       |  1 +
 vmdb/spec/models/mixins/retirement_mixin_spec.rb | 30 ++++++++++++++++++++++++
 2 files changed, 31 insertions(+)

Comment 15 Milan Falešník 2016-03-18 10:26:19 UTC
5.4.5.2:

I have set the retirement date 2 days into the future and put the retirement warning for 1 week. I got this e-mail:

Policy Succeeded

Policy 'spam spam spam', Succeeded

Event:	VM Retirement Warning
Entity:	(VmVmware) test_mfalesni_retire

Comment 17 errata-xmlrpc 2016-03-29 14:17:38 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.

https://rhn.redhat.com/errata/RHBA-2016-0171.html