mirror of https://github.com/apache/druid.git
IndexTask: Print metrics even if finishJob fails
This commit is contained in:
parent
3544b7ec4a
commit
bf158102c4
|
@ -368,9 +368,11 @@ public class IndexTask extends AbstractFixedIntervalTask
|
||||||
}
|
}
|
||||||
|
|
||||||
plumber.persist(firehose.commit());
|
plumber.persist(firehose.commit());
|
||||||
plumber.finishJob();
|
|
||||||
|
|
||||||
// Output metrics
|
try {
|
||||||
|
plumber.finishJob();
|
||||||
|
}
|
||||||
|
finally {
|
||||||
log.info(
|
log.info(
|
||||||
"Task[%s] took in %,d rows (%,d processed, %,d unparseable, %,d thrown away) and output %,d rows",
|
"Task[%s] took in %,d rows (%,d processed, %,d unparseable, %,d thrown away) and output %,d rows",
|
||||||
getId(),
|
getId(),
|
||||||
|
@ -380,6 +382,7 @@ public class IndexTask extends AbstractFixedIntervalTask
|
||||||
metrics.thrownAway(),
|
metrics.thrownAway(),
|
||||||
metrics.rowOutput()
|
metrics.rowOutput()
|
||||||
);
|
);
|
||||||
|
}
|
||||||
|
|
||||||
// We expect a single segment to have been created.
|
// We expect a single segment to have been created.
|
||||||
return Iterables.getOnlyElement(pushedSegments);
|
return Iterables.getOnlyElement(pushedSegments);
|
||||||
|
|
Loading…
Reference in New Issue