Bug 1398344

Summary: Policy Event.Miq Policy Sets fields filter out all the records if those are used in Report's Filter
Product: Red Hat CloudForms Management Engine Reporter: Ievgen Zapolskyi <izapolsk>
Component: ReportingAssignee: Gregg Tanzillo <gtanzill>
Status: CLOSED DEFERRED QA Contact: Ievgen Zapolskyi <izapolsk>
Severity: medium Docs Contact:
Priority: medium    
Version: 5.6.0CC: jhardy, obarenbo, yrudman
Target Milestone: GA   
Target Release: cfme-future   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard: report
Fixed In Version: Doc Type: If docs needed, set a value
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2018-08-15 13:55:40 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: Bug
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: CFME Core Target Upstream Version:

Description Ievgen Zapolskyi 2016-11-24 13:50:06 UTC
Description of problem:
It seems Policy Event.Miq Policy Sets broken down.
F.e. There is report called "Policy Events for Last Week - Sample 2". 
I have policy events where "Miq Policy Set->Set Type" == 'MiqPolicySet'.
If I remove that report's filter rule, I'll see a list of Miq Policy fields for my policy events.
But If I add filter rule "Miq Policy Set->Set Type" contains 'MiqPolicySet', I'll receive empty report. 
This is true for any field of Miq Policy Set entity.


Version-Release number of selected component (if applicable):
5.6.3.2

How reproducible:
100%

Steps to Reproduce:
1. Generate policy events using any way.
F.e.
1.1 Create Policy Profile + Policy + Condition + Events (Condition can check power state for instance)
1.2. Assign this profile to any vm
1.3. Power on/off the vm
1.4 make sure there are some policy events in policy_events table  
2. Go to Cloud Intel->Reports and select report All Reports->Events->Policy->"Policy Events for Last Week - Sample 2"
3. Add this report to queue and check its results when it is generated

Actual results:
the report didn't collect any data. The report will display expected data if filtering rule "Policy Event.Miq Policy Sets : Date Created" >= "7 Days Ago"
is removed

Expected results:
Information about Policy Sets should be displayed

Comment 4 Yuri Rudman 2018-08-15 13:55:40 UTC
Closing this BZ since 5.6 is in "Maintenance Support" phase.
Please check on latest released version and create another BZ if needed.