Bug 1431097

Summary: "java.lang.IllegalArgumentException: NaN" is logged in the server.log file when trying to store BaseLine values in the database
Product: [JBoss] JBoss Operations Network Reporter: bkramer <bkramer>
Component: DatabaseAssignee: Michael Burman <miburman>
Status: CLOSED ERRATA QA Contact: Jeeva Kandasamy <jkandasa>
Severity: medium Docs Contact:
Priority: medium    
Version: JON 3.3.8CC: fbrychta, jkandasa, spinder
Target Milestone: DR01Keywords: Triaged
Target Release: JON 3.3.9   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: Doc Type: If docs needed, set a value
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2017-10-02 17:21:51 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:
Bug Depends On: 1431100    
Bug Blocks:    

Description bkramer 2017-03-10 11:51:11 UTC
Description of problem:
This issue was supposed to be fixed in the Bugzilla https://bugzilla.redhat.com/show_bug.cgi?id=1315314 and in the JBoss ON 3.3.8 but that does not seem to be the case.

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

How reproducible:
Sometimes (not clear in what situations NaN values are generated)

Steps to Reproduce:
1. 
2.
3.

Actual results:

The following error is logged every time when JBoss ON tries to add NaN value in the database:
****************************
ERROR [org.jboss.as.ejb3.invocation] (RHQScheduler_Worker-1) JBAS014134: EJB Invocation failed on component MeasurementBaselineManagerBean for method public abstract long org.rhq.enterprise.server.measurement.MeasurementBaselineManagerLocal.calculateAutoBaselines(long,long): javax.ejb.EJBException: java.lang.RuntimeException: Auto-calculation failure
...
Caused by: java.lang.RuntimeException: Auto-calculation failure
...
Caused by: javax.ejb.EJBTransactionRolledbackException: Transaction rolled back
...
Caused by: javax.transaction.RollbackException: ARJUNA016053: Could not commit transaction.
...
Caused by: javax.persistence.PersistenceException: org.hibernate.exception.GenericJDBCException: could not insert: [org.rhq.core.domain.measurement.MeasurementBaseline]
...
Caused by: java.lang.IllegalArgumentException: NaN
****************************


Expected results:

Errors are not logged.


Additional info:

Comment 3 Michael Burman 2017-03-10 13:06:50 UTC
Fixed in the master:

commit 623258887dd3b849a2d9ee0688280a6aaf177c12
Author: Michael Burman <miburman>
Date:   Fri Mar 10 15:06:05 2017 +0200

    [BZ 1431097] Fix NaN comparison

Comment 5 Simeon Pinder 2017-09-01 15:34:21 UTC
Moving to ON_QA as available for test with the following binary:
http://download.eng.bos.redhat.com/brewroot/packages/org.jboss.on-jboss-on-parent/3.3.0.GA/133/maven/org/jboss/on/jon-server-patch/3.3.0.GA/jon-server-patch-3.3.0.GA.zip

*NOTE Build represents JON 3.3.9 DR01 build.

Please report issues as you encounter them.

Comment 7 Jeeva Kandasamy 2017-09-18 10:25:50 UTC
It's been 6 days. I don't see any error. Baselines are computed as expected. Hence, marking as verified

Version info:
-------------
JON 3.3.0.GA Update 09
Build Number : 74b22f5:8c38c0a

Comment 8 errata-xmlrpc 2017-10-02 17:21:51 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://access.redhat.com/errata/RHEA-2017:2846