Bug 696697 - Don't allow negative limit value to be set [RFE]
Summary: Don't allow negative limit value to be set [RFE]
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Red Hat Enterprise MRG
Classification: Red Hat
Component: cumin
Version: 2.0
Hardware: Unspecified
OS: Unspecified
low
low
Target Milestone: 2.0.1
: ---
Assignee: Trevor McKay
QA Contact: Jan Sarenik
URL:
Whiteboard:
Depends On:
Blocks: 723887
TreeView+ depends on / blocked
 
Reported: 2011-04-14 16:26 UTC by Trevor McKay
Modified: 2012-03-15 11:50 UTC (History)
4 users (show)

Fixed In Version: cumin-0.1.4840-1
Doc Type: Bug Fix
Doc Text:
The user interface allowed negative maximum allowance values to be entered when editing a limit under the "Limits" tab. Although the system accepted the negative value and displayed it in the user interface, internally it treated the value as if it were 0 (zero). This update changes this behavior so that entering a negative maximum allowance value causes Cumin to display an error message, and internally the limit is not changed.
Clone Of:
Environment:
Last Closed: 2011-09-07 16:45:27 UTC
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
Red Hat Product Errata RHSA-2011:1249 0 normal SHIPPED_LIVE Moderate: Red Hat Enterprise MRG Grid 2.0 security, bug fix and enhancement update 2011-09-07 16:40:45 UTC

Description Trevor McKay 2011-04-14 16:26:25 UTC
Description of problem:

Cumin curently allows negative limit values.  Condor apparently allows it as well, but this is nonsensical.  Limit values should have a floor of 0.


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


How reproducible:
100%

Steps to Reproduce:
1.  Run a job with a concurrency_limit value
2.  Use cumin to dynamically set the limit to a negative number
  
Actual results:

The limit is changed.

Expected results:

Cumin should change the value to 0 before submitting the change.

Additional info:

Comment 1 Trevor McKay 2011-05-20 16:49:02 UTC
Revision 4774.

Comment 2 Trevor McKay 2011-05-20 17:00:41 UTC
    Technical note added. If any revisions are required, please edit the "Technical Notes" field
    accordingly. All revisions will be proofread by the Engineering Content Services team.
    
    New Contents:
Cause
    The UI allows negative max allowance values to be entered when editing a limit under the "Limits" tab.

Consequence
    The system accepts the negative value and displays a negative max allowance for the limit.  Practically, the system behaves as if the max allowance is 0.  However, displaying a negative value on the screen may cause confusion.

Fix
    Negative max allowance values are set to 0 before they are submitted.

Result
    When the "Limits" screen updates, the max allowance value will be shown as 0 if a negative max allowance value was entered.

Comment 3 Trevor McKay 2011-05-31 18:41:37 UTC
Add some form validation for this too.

Comment 4 Trevor McKay 2011-06-17 17:52:32 UTC
Revision 4799, error dialog added.

Comment 5 Trevor McKay 2011-06-17 17:52:32 UTC
    Technical note updated. If any revisions are required, please edit the "Technical Notes" field
    accordingly. All revisions will be proofread by the Engineering Content Services team.
    
    Diffed Contents:
@@ -5,7 +5,7 @@
     The system accepts the negative value and displays a negative max allowance for the limit.  Practically, the system behaves as if the max allowance is 0.  However, displaying a negative value on the screen may cause confusion.
 
 Fix
-    Negative max allowance values are set to 0 before they are submitted.
+    Limit value is validated and is not allowed to be zero.
 
 Result
-    When the "Limits" screen updates, the max allowance value will be shown as 0 if a negative max allowance value was entered.+    User is presented with a standard cumin form error dialog if a negative limit is entered and no change is made to the limit.

Comment 6 Jan Sarenik 2011-06-24 10:16:22 UTC
Message when I try to set negative limit:
  The 'Max Allowance' field may not be less than zero

Verified in cumin-0.1.4840-1.el5

Comment 7 Douglas Silas 2011-08-09 14:48:12 UTC
    Technical note updated. If any revisions are required, please edit the "Technical Notes" field
    accordingly. All revisions will be proofread by the Engineering Content Services team.
    
    Diffed Contents:
@@ -1,11 +1 @@
-Cause
+The user interface allowed negative maximum allowance values to be entered when editing a limit under the "Limits" tab. Although the system accepted the negative value and displayed it in the user interface, internally it treated the value as if it were 0 (zero). This update changes this behavior so that entering a negative maximum allowance value causes Cumin to display an error message, and internally the limit is not changed.-    The UI allows negative max allowance values to be entered when editing a limit under the "Limits" tab.
-
-Consequence
-    The system accepts the negative value and displays a negative max allowance for the limit.  Practically, the system behaves as if the max allowance is 0.  However, displaying a negative value on the screen may cause confusion.
-
-Fix
-    Limit value is validated and is not allowed to be zero.
-
-Result
-    User is presented with a standard cumin form error dialog if a negative limit is entered and no change is made to the limit.

Comment 8 errata-xmlrpc 2011-09-07 16:45:27 UTC
An advisory has been issued which should help the problem
described in this bug report. This report is therefore being
closed with a resolution of ERRATA. For more information
on therefore solution and/or where to find the updated files,
please follow the link below. You may reopen this bug report
if the solution does not work for you.

http://rhn.redhat.com/errata/RHSA-2011-1249.html


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