|
From: <jt...@hy...> - 2007-03-20 20:35:46
|
Author: jtravis Date: 2007-03-20 12:35:41 -0800 (Tue, 20 Mar 2007) New Revision: 3796 URL: http://svn.hyperic.org/?view=rev&root=Hyperic+HQ&revision=3796 Modified: trunk/src/org/hyperic/hq/measurement/server/session/MeasurementData.java Log: Revert back to BigDecimal, since underflows and other floating point errors will cause measurement data to not be inserted. The original Sorry error is likely fixed by the change to DataManager which dealt with processing the exception of batch (logic error) Modified: trunk/src/org/hyperic/hq/measurement/server/session/MeasurementData.java =================================================================== --- trunk/src/org/hyperic/hq/measurement/server/session/MeasurementData.java 2007-03-20 20:19:17 UTC (rev 3795) +++ trunk/src/org/hyperic/hq/measurement/server/session/MeasurementData.java 2007-03-20 20:35:41 UTC (rev 3796) @@ -26,10 +26,11 @@ package org.hyperic.hq.measurement.server.session; import java.io.Serializable; +import java.math.BigDecimal; public class MeasurementData implements Serializable { private MeasurementDataId _id; - private double _value; + private BigDecimal _value; public MeasurementData() { } @@ -42,11 +43,11 @@ _id = id; } - public double getValue() { + public BigDecimal getValue() { return _value; } - protected void setValue(double value) { + protected void setValue(BigDecimal value) { _value = value; } |