sv2000 commented on a change in pull request #3164:
URL: https://github.com/apache/incubator-gobblin/pull/3164#discussion_r534424937
##########
File path:
gobblin-cluster/src/main/java/org/apache/gobblin/cluster/GobblinHelixTask.java
##########
@@ -179,11 +181,12 @@ public TaskResult run() {
log.error("Actual task {} failed in creation due to {}, will request new
container to schedule it",
this.taskId, te.getMessage());
this.taskMetrics.helixTaskTotalCancelled.incrementAndGet();
- return new TaskResult(TaskResult.Status.FAILED,
Throwables.getStackTraceAsString(te));
+ return new TaskResult(TaskResult.Status.FAILED, "Root cause:" +
ExceptionUtils.getRootCauseMessage(te)
+ + ", refer to container log for the whole stacktrace");
} catch (Throwable t) {
- log.error("Actual task {} failed due to {}", this.taskId,
t.getMessage());
+ log.error(String.format("Actual task %s failed due to:", this.taskId),
t);
this.taskMetrics.helixTaskTotalCancelled.incrementAndGet();
- return new TaskResult(TaskResult.Status.FAILED,
Throwables.getStackTraceAsString(t));
+ return new TaskResult(TaskResult.Status.FAILED, "Refer to container log
for exception details.");
Review comment:
Just empty string instead of "Refer to container log..."?
##########
File path:
gobblin-cluster/src/main/java/org/apache/gobblin/cluster/GobblinHelixTask.java
##########
@@ -179,11 +181,12 @@ public TaskResult run() {
log.error("Actual task {} failed in creation due to {}, will request new
container to schedule it",
this.taskId, te.getMessage());
this.taskMetrics.helixTaskTotalCancelled.incrementAndGet();
- return new TaskResult(TaskResult.Status.FAILED,
Throwables.getStackTraceAsString(te));
+ return new TaskResult(TaskResult.Status.FAILED, "Root cause:" +
ExceptionUtils.getRootCauseMessage(te)
+ + ", refer to container log for the whole stacktrace");
Review comment:
Drop the "refer to...."
----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
[email protected]