Bug 1202327

Summary: Relax the 1h minimum Session timeout validation
Product: [JBoss] JBoss Operations Network Reporter: Thomas Heute <theute>
Component: UIAssignee: Libor Zoubek <lzoubek>
Status: CLOSED ERRATA QA Contact: Filip Brychta <fbrychta>
Severity: medium Docs Contact:
Priority: unspecified    
Version: JON 3.3.1CC: fbrychta, loleary, miburman, theute
Target Milestone: ER01Keywords: Triaged
Target Release: JON 3.3.2   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2015-04-30 16:11:09 UTC Type: Enhancement
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:

Description Thomas Heute 2015-03-16 12:07:15 UTC
Description of problem:
A user would like to be able to set 15min as timeout session but in the UI (Administration -> System Settings) a user cannot set a session timeout below 1h.

In the form, the user is asked for a time in hours and it has to be an integer otherwise the form won't be submitted.

The input should be in minutes.

Comment 3 Thomas Heute 2015-03-16 12:16:05 UTC
Note: A workaround is to change the value directly in the database but the next time the form is opened (to change any value on it) it will show 0 and won't validate until the user set the value to 1h

Comment 4 Libor Zoubek 2015-03-17 16:04:44 UTC
Session timeout is stored in RHQ_SYSTEM_CONFIG table in milliseconds, to set it ie. to 15min following query had to be executed:

update table RHQ_SYSTEM_CONFIG set property_value=900000 where property_key='RHQ_SESSION_TIMEOUT';

Once done, restart JON server to take effect.

Comment 5 Libor Zoubek 2015-03-18 15:27:41 UTC
Actually .. I just found out the workaround won't work. There's a piece of code  with hardcoded session timeout minimum (equal to 1h) which prevents UI to enforce any value lower than 1h from settings.

Comment 8 Libor Zoubek 2015-03-23 09:25:02 UTC
branch:  master
link:    https://github.com/rhq-project/rhq/commit/24013f6ca
time:    2015-03-23 10:23:10 +0100
commit:  24013f6ca37fe8231bb8568be6d6779547b38dee
author:  Libor Zoubek - lzoubek
message: Bug 1202327 - Relax the 1h minimum Session timeout validation
         Show GUI Session Timeout in minutes, changed minimum acceptable
         timeout to 1 minute

Comment 10 Michael Burman 2015-04-02 14:41:12 UTC
Had to manually merge to the jon3.3.x:

commit 6dc2525efe787c50e027125088ac9996784059d7
Author: Michael Burman <miburman>
Date:   Thu Apr 2 17:40:13 2015 +0300

    Bug 1202327 - Relax the 1h minimum Session timeout validation
    
    Show GUI Session Timeout in minutes, changed minimum acceptable timeout to 1
    minute
    
     Conflicts:
        modules/enterprise/gui/coregui/src/main/resources/org/rhq/coregui/client/Messages.properties
        modules/enterprise/gui/coregui/src/main/resources/org/rhq/coregui/client/Messages_cs.properties
        modules/enterprise/gui/coregui/src/main/resources/org/rhq/coregui/client/Messages_de.properties
        modules/enterprise/gui/coregui/src/main/resources/org/rhq/coregui/client/Messages_ja.properties

Comment 11 Simeon Pinder 2015-04-13 04:14:39 UTC
Moving to ON_QA for testing with latest cumulative patch build:
https://brewweb.devel.redhat.com//buildinfo?buildID=429507

Note: Build maps to JON 3.3.2 ER01 build.

Comment 12 Filip Brychta 2015-04-13 16:33:32 UTC
Verified cases from comments 7 and 9.
Only one problem which was visible on JON 3.3.0.GA as well bz 1211341.
Created new bz for that and marking this as verified.

Comment 14 errata-xmlrpc 2015-04-30 16:11:09 UTC
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/RHSA-2015-0920.html