Bug 1201932
Summary: | Undefined local variable or method 'count' for Metric::Purging:Module(NameError) | ||||||
---|---|---|---|---|---|---|---|
Product: | Red Hat CloudForms Management Engine | Reporter: | Jared Deubel <jdeubel> | ||||
Component: | Providers | Assignee: | Jason Frey <jfrey> | ||||
Status: | CLOSED ERRATA | QA Contact: | Nandini Chandra <nachandr> | ||||
Severity: | low | Docs Contact: | |||||
Priority: | medium | ||||||
Version: | 5.2.0 | CC: | fdewaley, jfrey, jhardy, jocarter, mfeifer, nachandr, obarenbo, snansi, tcarlin | ||||
Target Milestone: | GA | ||||||
Target Release: | 5.4.0 | ||||||
Hardware: | Unspecified | ||||||
OS: | Unspecified | ||||||
Whiteboard: | |||||||
Fixed In Version: | Doc Type: | Bug Fix | |||||
Doc Text: |
In the previous version of CloudForms Management Engine, attempting to purge metrics data manually with the purge_metrics.rb script would result in an undefined local variable error. This was because a local variable 'count' was not defined in the context of the script. This bug was fixed by ensuring that count was defined in the context of the script. Manual purges of the metrics data work correctly in the new version of CloudForms Management Engine.
|
Story Points: | --- | ||||
Clone Of: | Environment: | ||||||
Last Closed: | 2015-06-16 12:53:02 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: | |||||||
Attachments: |
|
Description
Jared Deubel
2015-03-13 21:20:34 UTC
I have to verify this is a bug on 5.2, but it clearly a bug on upstream. I'm really surprised the specs did not find this as it is definitely tested. customer for case 01377209 asks which data can be removed safely from the db to reduce the impact before he vacuums the database (external). he states that at the current groth rate, the appliance will no longer work in a couple weeks. as such requesting hotfix... Yup, definitely seems to be the same bug on 5.2. I am simply amazed that no one else has seen this before. New commit detected on manageiq/master: https://github.com/ManageIQ/manageiq/commit/f20800046e994760d5cc1bae7873e262ec398fd6 commit f20800046e994760d5cc1bae7873e262ec398fd6 Author: Jason Frey <jfrey> AuthorDate: Thu Mar 19 17:14:22 2015 -0400 Commit: Jason Frey <jfrey> CommitDate: Thu Mar 19 17:16:04 2015 -0400 Fix issue where count was undefined when purge called with a block. Note that this only really affects calling .purge from the tools/purge_metrics.rb script. Since normal scheduled purging does not pass the block it works correctly. https://bugzilla.redhat.com/show_bug.cgi?id=1201932 vmdb/app/models/metric/purging.rb | 14 +++--- vmdb/spec/models/metric/purging_spec.rb | 76 +++++++++++++++++++++++++++++++++ 2 files changed, 83 insertions(+), 7 deletions(-) create mode 100644 vmdb/spec/models/metric/purging_spec.rb Created attachment 1006871 [details]
explain_metric_query
Explain queries for the metrics table.
Jason, can this be cherry-pick back to 5.3.z? Verified in 5.4.0.0.24 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-2015-1100.html The needinfo request[s] on this closed bug have been removed as they have been unresolved for 1000 days |