Bug 1114600 - Cannot load Metric red error when client time is different from server
Summary: Cannot load Metric red error when client time is different from server
Keywords:
Status: CLOSED NOTABUG
Alias: None
Product: JBoss Operations Network
Classification: JBoss
Component: UI
Version: JON 3.2
Hardware: Unspecified
OS: Unspecified
medium
high
Target Milestone: ER05
: JON 3.3.0
Assignee: Jirka Kremser
QA Contact: Mike Foley
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2014-06-30 13:12 UTC by Armine Hovsepyan
Modified: 2015-09-03 00:02 UTC (History)
3 users (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2014-10-14 13:46:35 UTC
Type: Bug
Embargoed:


Attachments (Terms of Use)
cannot_load_metrics (185.10 KB, image/png)
2014-06-30 13:12 UTC, Armine Hovsepyan
no flags Details

Description Armine Hovsepyan 2014-06-30 13:12:30 UTC
Created attachment 913402 [details]
cannot_load_metrics

Description of problem:
Cannot load Metric red error  when client time is different from server

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

How reproducible:
always

Steps to Reproduce:
1. Enter server GUI of JON 3.2.2 from Client having different time zone than server does
2. Navigate  to "RHQ Storage Node" resource
3. Navigate to "Cassandra Server JVM"   resource -> Metrics
4. Select 1h metrics
5. Navigate to "Memory Subsystem" resource 

Actual results:
Cannot load Metric red error

Expected results:
Metrics loaded without issues

Additional info:
When on Metrics Subsystem new time diff is selected, no error is visible

+++ Similar bug   #848494 +++

Comment 3 Simeon Pinder 2014-09-29 08:12:32 UTC
Moving into ER05 as didn't make the ER04 cut.

Comment 4 Jay Shaughnessy 2014-10-10 13:27:02 UTC
Taking this to offload jkremser.  He says it's likely due to used Date() in the GUI code...

Comment 6 Jirka Kremser 2014-10-13 16:03:40 UTC
branch:  master
link:    https://github.com/rhq-project/rhq/commit/546cf53e3
time:    2014-10-13 18:00:52 +0200
commit:  546cf53e3c58825ca089aa90e49f1897de937887
author:  Jirka Kremser - jkremser
message: [BZ 1114600] - Cannot load Metric red error when client time is
         different from server - trying to resolve the time into # of
         milliseconds on the server side where the referential time zone
         is used. Introducing a new class called Moment for storing 5
         integers: year, month, day, hours, minutes.


it's not ready for cherry-picking, it needs more manual testing, before going to POST

Comment 7 Jirka Kremser 2014-10-14 11:27:55 UTC
branch:  master
link:    https://github.com/rhq-project/rhq/commit/cb5078b36
time:    2014-10-14 13:24:06 +0200
commit:  cb5078b367f9ed8d268669fbdc122422e08dfa19
author:  Jirka Kremser - jkremser
message: [BZ 1114600] - Cannot load Metric red error when client time is
         different from server - Moving Moment.java to core/domain
         module. There was CNF exception during the install, but also
         CLI can benefit from this timezone independent class as well.
         (because depending on number millis from 1970 is confusing - it
         may return different number on different timezones)

Comment 8 Jirka Kremser 2014-10-14 13:46:35 UTC
branch:  master
link:    https://github.com/rhq-project/rhq/commit/344842913
time:    2014-10-14 14:17:09 +0200
commit:  3448429138161a1fd329b3f937488ee65fd9a199
author:  Jirka Kremser - jkremser
message: [BZ 1114600] - Cannot load Metric red error when client time is
         different from server - Renaming Moment.java -> Instant.java to
         be 'language compliant' with Joda time and Java 8 time API.


branch:  master
link:    https://github.com/rhq-project/rhq/commit/535e872d1
time:    2014-10-14 15:40:50 +0200
commit:  535e872d1c204b2e7815719861a39fd93d91838c
author:  Jirka Kremser - jkremser
message: [BZ 1114600] - Bulk revert of 3448429138161, cb5078b367f9e and
         546cf53e3c588 - I reproduced the issue by changing the time on
         a client (browser) machine. But we don't support such a
         behavior. When changing only the timezone, I didn't reproduce
         the exception.

         * Revert "[BZ 1114600] - Cannot load Metric red error when
         client time is different from server - Renaming Moment.java ->
         Instant.java to be 'language compliant' with Joda time and Java
         8 time API."

         This reverts commit 3448429138161a1fd329b3f937488ee65fd9a199.

         * Revert "[BZ 1114600] - Cannot load Metric red error when
         client time is different from server - Moving Moment.java to
         core/domain module. There was CNF exception during the install,
         but also CLI can benefit from this timezone independent class
         as well. (because depending on number millis from 1970 is
         confusing - it may return different number on different
         timezones)"

         This reverts commit cb5078b367f9ed8d268669fbdc122422e08dfa19.

         * Revert "[BZ 1114600] - Cannot load Metric red error when
         client time is different from server - trying to resolve the
         time into # of milliseconds on the server side where the
         referential time zone is used. Introducing a new class called
         Moment for storing 5 integers: year, month, day, hours,
         minutes."

         This reverts commit 546cf53e3c58825ca089aa90e49f1897de937887.



Closing it as NOTABUG, because we don't support clients that have wrong time set. If the timezone is different, but the time itself is correct, it is working as expected.

Hence, mass revert of commits: 
3448429138161
cb5078b367f9e
546cf53e3c588


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