Issue #2359 log exceptions in FFTI processing

Change-Id: Iec1c743352187de071f4b9840f1672bff531ba94

Former-commit-id: 1d9229a4a6 [formerly d289eb1b55] [formerly 43b75928e4 [formerly 2abd0cc65b6fe98dc95e11b5b8d53a325c0f2074]]
Former-commit-id: 43b75928e4
Former-commit-id: daba59930d
This commit is contained in:
Nate Jensen 2014-01-10 08:57:18 -06:00
parent b833c4333c
commit 8b5ce7c07f

View file

@ -55,6 +55,7 @@ import com.raytheon.uf.edex.plugin.ffmp.FFMPGenerator;
* July 13, 2012 dhladky Revamped to help memory
* 02/01/13 1569 D. Hladky Added constants
* 02/25/13 1660 D. Hladky Moved FFTI processing to help with mosaic memory usage
* 01/10/14 2359 njensen Fix exception logging
*
* </pre>
*
@ -235,8 +236,8 @@ public class FFTI implements Runnable {
for (int j = 0; j < sites.size(); j++) {
FFTIAccum faccum = ffmpgen.getAccumulationForSite(displayName,
sites.get(j), dataKey, duration,
FFTIAccum faccum = ffmpgen.getAccumulationForSite(
displayName, sites.get(j), dataKey, duration,
source.getUnit());
if (faccum != null) {
@ -278,8 +279,8 @@ public class FFTI implements Runnable {
source = ffmpgen.getSourceConfig().getSourceByDisplayName(
fftiSourceKey);
accum = ffmpgen.getAccumulationForSite(fftiSourceKey, fftiSiteKey,
fftiSiteKey, duration, source.getUnit());
accum = ffmpgen.getAccumulationForSite(fftiSourceKey,
fftiSiteKey, fftiSiteKey, duration, source.getUnit());
if (accum != null) {
accum.setUnit(source.getUnit());
@ -430,11 +431,11 @@ public class FFTI implements Runnable {
}
}
} catch (Exception e) {
statusHandler.handle(
Priority.ERROR,
statusHandler
.handle(Priority.ERROR,
"Failed to evaluate Ratio/Diff. "
+ attribute.getAttributeName() + ": " + displayName
+ "\n" + e);
+ attribute.getAttributeName() + ": "
+ displayName, e);
}
}
@ -521,8 +522,10 @@ public class FFTI implements Runnable {
}
} catch (Exception e) {
statusHandler
.handle(Priority.ERROR, "failed to transmit FFTI alert. "
+ attribute.getAttributeName() + " Value: " + value);
.handle(Priority.ERROR,
"failed to transmit FFTI alert. "
+ attribute.getAttributeName() + " Value: "
+ value, e);
}
}
@ -576,8 +579,10 @@ public class FFTI implements Runnable {
}
} catch (Exception e) {
statusHandler
.handle(Priority.ERROR, "failed to transmit FFTI alert. "
+ attribute.getAttributeName() + " Value: " + value);
.handle(Priority.ERROR,
"failed to transmit FFTI alert. "
+ attribute.getAttributeName() + " Value: "
+ value, e);
}
}
@ -649,8 +654,8 @@ public class FFTI implements Runnable {
ffmpgen.logger.debug("FFTI: finsihed evaluating sources");
}
} catch (Exception e) {
statusHandler.handle(Priority.ERROR, "failed to evaluate FFTI. "
+ e);
statusHandler
.handle(Priority.ERROR, "failed to evaluate FFTI. ", e);
} finally {
ffmpgen.fftiSources.clear();
ffmpgen.fftiDone = true;
@ -787,7 +792,8 @@ public class FFTI implements Runnable {
* @return
*/
public static Double getGap(FFMPDataContainer qpeContainer,
SourceXML ffmpQSource, Date curdate, double duration, String qSiteKey) {
SourceXML ffmpQSource, Date curdate, double duration,
String qSiteKey) {
long timeBack = (long) (duration * TimeUtil.MILLIS_PER_HOUR);
Date backDate = new Date(curdate.getTime() - timeBack);