Bug 1567254
Summary: | total costs no longer showing in any chargeback report if they are the only columns in the report | |||
---|---|---|---|---|
Product: | Red Hat CloudForms Management Engine | Reporter: | Felix Dewaleyne <fdewaley> | |
Component: | Reporting | Assignee: | Joe Rafaniello <jrafanie> | |
Status: | CLOSED CURRENTRELEASE | QA Contact: | Tasos Papaioannou <tpapaioa> | |
Severity: | medium | Docs Contact: | ||
Priority: | medium | |||
Version: | 5.8.0 | CC: | cpelland, fdewaley, gtanzill, jrafanie, mfeifer, obarenbo, tpapaioa, yrudman | |
Target Milestone: | GA | Keywords: | TestOnly, ZStream | |
Target Release: | 5.10.0 | |||
Hardware: | All | |||
OS: | All | |||
Whiteboard: | ||||
Fixed In Version: | 5.10.0.0 | Doc Type: | If docs needed, set a value | |
Doc Text: | Story Points: | --- | ||
Clone Of: | ||||
: | 1576099 1576101 (view as bug list) | Environment: | ||
Last Closed: | 2019-02-11 14:02:36 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: | ||||
Bug Depends On: | ||||
Bug Blocks: | 1576099, 1576101 |
Description
Felix Dewaleyne
2018-04-13 16:37:14 UTC
> the old reports no longer show any data, new reports won't either
Felix, I guess I was looking at this part too... that new reports weren't working. Clearly, they were for me. Are you seeing them work? I checked that first, because if new reports weren't working, it was highly likely that old reports wouldn't either.
Hi Felix, See prior attachment. We have €0.00 in the database directly for the report result details so, either they're mistaken about saved reports showing the correct data or somehow the database rows were modified since they worked. Are you sure this specific report was working with an older version? I am confused. See following attachment of the report I'm asking about... make sure this is the one and followup with what the customer says. Upon reviewing the case I'm also mistaken in reporting that reports were empty - they are empty or have a value of 0.
the customer's words were
Chargeback reports appear with Memory, CPU or Storage Total costs equal to zero if these are the only selected fields.
If I add the following Selected Fields when basing a report on Chargebac for Vms:
Memory Total Cost
CPU Total Cost
Storage Total Cost
Network I/O Used Cost
then, by themselves only the Network shows costs. To make it possible to have a complete costs, one needs also to add to the report the rest of the costs adding up, such as the Memory Allocated Cost, or the vCPUs Allocated cost, which are parts of the cost.
however from the exported reports they provided as you will see in attachment 1430563 [details] there is no value in some of the fields, leading me to this description.
while I'm waiting to hear if they have a copy of their 4.1 database, let me know if this helps.
Felix, I just wanted to let you know that I have recreated the problem. There's clearly a bug, where some fields, such as Memory Cost do not get calculated if another field like Memory Allocated Cost isn't also in the report. This is a bug and we'll fix it. Note, I did a quick look at the 5.8 vs. 5.7 code and it appears that this problem would have also existed in 5.7. From the prior comments, it's hard to understand if they're saying that this exact same report worked on 5.7. In other words, I think the same report would have empty values on both 5.7 and 5.8. I will try to verify what versions that have this problem and report back. I haven't fixed this yet but wanted to let you know that we understand the problem and how to fix it. (In reply to Joe Rafaniello from comment #15) > Felix, > > I just wanted to let you know that I have recreated the problem. There's > clearly a bug, where some fields, such as Memory Cost do not get calculated > if another field like Memory Allocated Cost isn't also in the report. This > is a bug and we'll fix it. > > Note, I did a quick look at the 5.8 vs. 5.7 code and it appears that this > problem would have also existed in 5.7. From the prior comments, it's hard > to understand if they're saying that this exact same report worked on 5.7. > In other words, I think the same report would have empty values on both 5.7 > and 5.8. I will try to verify what versions that have this problem and > report back. > > I haven't fixed this yet but wanted to let you know that we understand the > problem and how to fix it. thanks! New commit detected on ManageIQ/manageiq/master: https://github.com/ManageIQ/manageiq/commit/4b15db44d33ae6fe68fc861af2a84a112d6c8bf2 commit 4b15db44d33ae6fe68fc861af2a84a112d6c8bf2 Author: Joe Rafaniello <jrafanie> AuthorDate: Fri May 4 17:34:10 2018 -0400 Commit: Joe Rafaniello <jrafanie> CommitDate: Fri May 4 17:34:10 2018 -0400 Check all costs fields for relevancy for the report Fixes https://bugzilla.redhat.com/show_bug.cgi?id=1567254 If a user asks only for some of the fields (memory cost) in a chargeback report and they didn't request specific ones (memory allocated cost), we would skip calculating the memory cost because we thought it wasn't relevant. We need to check all cost fields to see if they're relevant for the requested fields in the report. app/models/chargeback_rate_detail.rb | 2 +- spec/models/chargeback_vm_spec.rb | 11 + 2 files changed, 12 insertions(+), 1 deletion(-) Verified on 5.10.0.3. |