Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix tag CU chart when there are no daily data #3376

Merged
merged 1 commit into from
Feb 9, 2018

Conversation

PanSpagetka
Copy link
Contributor

@PanSpagetka PanSpagetka commented Feb 6, 2018

Fix tag CU chart when there are not enough daily data.
I think, that source of this problem is hidden in generating reports, but because i think it is related to blocker bz, I just fix consequences and return to it later.

Links [Optional]

Related(ish) with https://bugzilla.redhat.com/show_bug.cgi?id=1540129

Steps for Testing/QA [Optional]

Select host with some C&U data, but not for all day.
Utilization -> Group By (tag) -> Daily

Screenshots

Before:
screencapture-localhost-3000-host-show-10000000000014-1517923395930

After:
screencapture-localhost-3000-host-show-10000000000014-1517923046039

@PanSpagetka PanSpagetka changed the title Fix tag CU chart when there are no data Fix tag CU chart when there are no daily data Feb 6, 2018
@PanSpagetka PanSpagetka force-pushed the fix-cu-chart-no-data-tag branch 2 times, most recently from 2d58a7c to 21d7bf6 Compare February 6, 2018 13:46
@lgalis
Copy link
Contributor

lgalis commented Feb 6, 2018

This does prevent the crash when there are no records with capture_interval_name = 'daily' but there are records with 'capture_interval_name = 'hourly' for multiple days.
there are specs errors with this change.
we need to look into the Interval field display - and how that relates to the hourly/daily data - and invalidate the group_by when there is no actual 'daily' utilization data

@PanSpagetka PanSpagetka force-pushed the fix-cu-chart-no-data-tag branch from 21d7bf6 to 5254e96 Compare February 7, 2018 08:33
@PanSpagetka PanSpagetka force-pushed the fix-cu-chart-no-data-tag branch from 5254e96 to 570c904 Compare February 7, 2018 10:22
@miq-bot
Copy link
Member

miq-bot commented Feb 7, 2018

Checked commit PanSpagetka@570c904 with ruby 2.3.3, rubocop 0.52.0, haml-lint 0.20.0, and yamllint 1.10.0
1 file checked, 0 offenses detected
Everything looks fine. 👍

@mzazrivec
Copy link
Contributor

@lgalis Are you OK with the proposed fix? Thanks.

@lgalis
Copy link
Contributor

lgalis commented Feb 8, 2018

This PR fixes the crash, so I am OK with it. We can look at addressing the no-data situation better in a different PR upstream.

@mzazrivec mzazrivec removed the blocker label Feb 8, 2018
@mzazrivec mzazrivec self-assigned this Feb 9, 2018
@mzazrivec mzazrivec added this to the Sprint 79 Ending Feb 12, 2018 milestone Feb 9, 2018
@mzazrivec mzazrivec merged commit 5dddefa into ManageIQ:master Feb 9, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants