sensordb2 1 éve
szülő
commit
cc3cc5417f

+ 5 - 10
db-api/src/main/java/db/DBVal.java

@@ -134,16 +134,11 @@ public class DBVal implements Serializable {
 	}
 
 	public String toString() {
-		try {
-			return String.format("[metricName:%s tags:%s utcTime:%d(ms) date:%s value:%f valueStatus:%s]\n",
-                    this.getMetricName(), this.getTags(), this.utcTime,
-					Util.uTCMilliSecondsToDateStringWithMs(this.utcTime),
-                    this.value,
-					this.valueStatus.toString());
-		} catch (ParseException e) {
-			e.printStackTrace();
-			return "";
-		}
+		return String.format("[metricName:%s tags:%s utcTime:%d(ms) date:%s value:%f valueStatus:%s]\n",
+				this.getMetricName(), this.getTags(), this.utcTime,
+				Util.uTCMilliSecondsToDateStringWithMs(this.utcTime),
+				this.value,
+				this.valueStatus.toString());
 	}
 }
 

+ 1 - 5
db-api/src/main/java/db/PointVals.java

@@ -25,11 +25,7 @@ public class PointVals implements Serializable {
 	private String[] toDateArray(long[] utcTimes) {
 		String[] result = new String[utcTimes.length];
 		for (int i=0;i<utcTimes.length;i++) {
-			try {
-				result[i] = Util.uTCMilliSecondsToDateStringWithMs(utcTimes[i]);
-			} catch (ParseException e) {
-				result[i] = "";
-			}
+			result[i] = Util.uTCMilliSecondsToDateStringWithMs(utcTimes[i]);
 		}
 		return result;
 	}