Bug 536523 (RHQ-864)

Summary: On the Metric Data subtab, for data that is not even being collected, shows zeros instead of n/a or blank
Product: [Other] RHQ Project Reporter: Jeff Weiss <jweiss>
Component: No ComponentAssignee: RHQ Project Maintainer <rhq-maint>
Status: CLOSED WONTFIX QA Contact: Mike Foley <mfoley>
Severity: medium Docs Contact:
Priority: medium    
Version: 1.1preCC: asantos, ccrouch, cwelton, dajohnso, jshaughn
Target Milestone: ---Keywords: SubBug
Target Release: ---   
Hardware: All   
OS: All   
URL: http://jira.rhq-project.org/browse/RHQ-864
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2014-05-15 21:14:53 UTC Type: ---
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:
Bug Depends On:    
Bug Blocks: 565628    

Description Jeff Weiss 2008-09-19 14:27:00 UTC
<joseph> jweiss, probably because avg(col) in sql will always give a real result back
<jweiss> joseph: even if there are no rows?
<joseph> yup
<jweiss> seems like it should give NaN or something

I think maybe update update the code+sql to check for zero rows first, and then change the display to NaN or or n/a or some non-number.  

Comment 1 Red Hat Bugzilla 2009-11-10 21:18:28 UTC
This bug was previously known as http://jira.rhq-project.org/browse/RHQ-864


Comment 2 wes hayutin 2010-02-16 16:53:36 UTC
Temporarily adding the keyword "SubBug" so we can be sure we have accounted for all the bugs.

keyword:
new = Tracking + FutureFeature + SubBug

Comment 3 wes hayutin 2010-02-16 16:58:52 UTC
making sure we're not missing any bugs in rhq_triage

Comment 4 Joseph Marques 2010-10-05 15:42:18 UTC
can't determine this because we don't know the difference between "not currently collecting" and "never have collected" - that discerning info is not stored anywhere.  the best we can do is show what we think the current numeric value is, but annotate some rows with "not currently collecting this metric"

Comment 5 Jeff Weiss 2010-10-05 15:49:28 UTC
I don't understand.  The problem was that even for metrics where not a single row of data was EVER collected, the stats would still have numbers in them.

How can the code not know there are zero rows?  It has to calculate the average.