Bug 1658373 - Default worker memory settings in the WebUI are incorrect and do not match the actual configured memory settings
Summary: Default worker memory settings in the WebUI are incorrect and do not match th...
Keywords:
Status: CLOSED CURRENTRELEASE
Alias: None
Product: Red Hat CloudForms Management Engine
Classification: Red Hat
Component: UI - OPS
Version: 5.10.0
Hardware: Unspecified
OS: Unspecified
high
high
Target Milestone: GA
: 5.11.0
Assignee: Harpreet Kataria
QA Contact: Jaroslav Henner
Red Hat CloudForms Documentation
URL:
Whiteboard:
Depends On:
Blocks: 1686902
TreeView+ depends on / blocked
 
Reported: 2018-12-11 21:34 UTC by Peter McGowan
Modified: 2020-01-02 16:22 UTC (History)
9 users (show)

Fixed In Version: 5.11.0.1
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
: 1686902 (view as bug list)
Environment:
Last Closed: 2019-12-13 14:55:05 UTC
Category: ---
Cloudforms Team: CFME Core
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)
Worker memory settings screenshot (81.58 KB, image/png)
2018-12-11 21:34 UTC, Peter McGowan
no flags Details

Description Peter McGowan 2018-12-11 21:34:49 UTC
Created attachment 1513536 [details]
Worker memory settings screenshot

Description of problem:
Reopening https://bugzilla.redhat.com/show_bug.cgi?id=1649781

Default worker memory settings in the WebUI are incorrect and do not match the actual configured memory settings

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

How reproducible:
Every time


Steps to Reproduce:
1. Navigate to Configuration -> Settings -> (appliance) -> Workers in the Ops UI
2. Note the default values of the Worker memory threshold settings (see screenshot), for example both generic and priority worker say 200MB
3. Now navigate to Configuration -> Settings -> (appliance) -> Workers in the Ops UI and observe the actual memory thresholds set in the configuration YAML.

Actual results:
The configuration YAML shows different defaults to the Ops UI 'Workers' page. For example the actual default for a Generic worker is 500MB, and for a Priority worker is 600MB

Expected results:
The 'Workers' page in the Ops UI should display the correct values.

Additional info:

Comment 5 Harpreet Kataria 2019-01-24 16:18:31 UTC
https://github.com/ManageIQ/manageiq-ui-classic/pull/5189

Comment 6 CFME Bot 2019-02-14 04:48:09 UTC
New commit detected on ManageIQ/manageiq-ui-classic/master:

https://github.com/ManageIQ/manageiq-ui-classic/commit/6a20b57e7b6268ff14c43f778b48ced5387568bf
commit 6a20b57e7b6268ff14c43f778b48ced5387568bf
Author:     Harpreet Kataria <hkataria>
AuthorDate: Wed Jan 23 18:37:31 2019 -0500
Commit:     Harpreet Kataria <hkataria>
CommitDate: Wed Jan 23 18:37:31 2019 -0500

    Fixed display of worker memory threshold settings

    Fixed couple of scenarios
    - Worker memory threshold of 1 GB or above was not reflected on Workers tab because https://github.com/ManageIQ/manageiq-ui-classic/blob/master/app/controllers/ops_controller/settings/common.rb#L997 value of variable `x` needs to be converted to integer value from a float so value can be selected correctly in the drop down.
    - If a value in yaml config file is set to as 600.megabytes, it is being returned as a string, so need to evaluate/convert the value so it can be correctly selected in the drop down.

    Fixes https://bugzilla.redhat.com/show_bug.cgi?id=1656873
    Fixes https://bugzilla.redhat.com/show_bug.cgi?id=1658373

 app/controllers/ops_controller/settings/common.rb | 6 +-
 spec/controllers/ops_controller/settings/common_spec.rb | 37 +
 2 files changed, 40 insertions(+), 3 deletions(-)

Comment 8 CFME Bot 2019-03-14 13:02:24 UTC
New commit detected on ManageIQ/manageiq-ui-classic/hammer:

https://github.com/ManageIQ/manageiq-ui-classic/commit/142b265e8d0cbc2e9e650d11c8a43e09c38258ff
commit 142b265e8d0cbc2e9e650d11c8a43e09c38258ff
Author:     Harpreet Kataria <hkataria>
AuthorDate: Wed Jan 23 18:37:31 2019 -0500
Commit:     Harpreet Kataria <hkataria>
CommitDate: Wed Jan 23 18:37:31 2019 -0500

    Fixed display of worker memory threshold settings

    Fixed couple of scenarios
    - Updated code to use `get_worker_setting` method
    - Worker memory threshold of 1 GB or above was not reflected on Workers tab because https://github.com/ManageIQ/manageiq-ui-classic/blob/master/app/controllers/ops_controller/settings/common.rb#L997 value of variable `x` needs to be converted to integer value from a float so value can be selected correctly in the drop down.
    - If a value in yaml config file is set to as 600.megabytes, it is being returned as a string, so need to evaluate/convert the value so it can be correctly selected in the drop down.

    Fixes https://bugzilla.redhat.com/show_bug.cgi?id=1656873
    Fixes https://bugzilla.redhat.com/show_bug.cgi?id=1658373

    (cherry picked from commit 6a20b57e7b6268ff14c43f778b48ced5387568bf)

 app/controllers/ops_controller/settings/common.rb | 57 +-
 spec/controllers/ops_controller/settings/common_spec.rb | 37 +
 2 files changed, 68 insertions(+), 26 deletions(-)

Comment 11 CFME Bot 2019-03-29 14:37:53 UTC
New commit detected on ManageIQ/manageiq-ui-classic/master:

https://github.com/ManageIQ/manageiq-ui-classic/commit/e1f3c405fe2e01a26b6a68eccbb01813da19e53e
commit e1f3c405fe2e01a26b6a68eccbb01813da19e53e
Author:     Harpreet Kataria <hkataria>
AuthorDate: Thu Mar 28 10:51:05 2019 -0400
Commit:     Harpreet Kataria <hkataria>
CommitDate: Thu Mar 28 10:51:05 2019 -0400

    Fixed display of default memory threshold correctly on new appliance

    Memory Threshold value of C & U Data Collectors, Refresh, VM Analysis Collectors workers on fresh appliance was not showing correctly.
    - Changed range calculation in the .step that sets the values for the drop down, to fix the issue where in rails the default config value of 2.gigabytes is converted to 2147483648 but the calculations in the .step method was generating that as 2147483644 causing the values to not match and not display the right one selected in the drop down.
    - Fixed the fetching of worker setting for MiqEmsMetricsCollectorWorker worker to be the same format as other workers.
    - Added additional value in VM Analysis Collectors drop down, because default for that in config is set to 2.gigabytes and drop down did not have that value present.

    Fixes https://bugzilla.redhat.com/show_bug.cgi?id=1658373

 app/controllers/ops_controller/settings/common.rb | 18 +-
 spec/controllers/ops_controller/settings/common_spec.rb | 8 +
 2 files changed, 17 insertions(+), 9 deletions(-)

Comment 12 Jaroslav Henner 2019-07-02 16:54:15 UTC
I changed the Priority worker memory and the change did propagate to the advanced config.


Note You need to log in before you can comment on or make changes to this bug.