prakharchaube commented on a change in pull request #721: URL: https://github.com/apache/nutch/pull/721#discussion_r786980017
########## File path: src/java/org/apache/nutch/util/NutchJob.java ########## @@ -81,4 +83,26 @@ public static void cleanupAfterFailure(Path tempDir, Path lock, FileSystem fs) } } + /** + * Method to return job failure log message. To be used across all Jobs + * + * @param name + * Name/Type of the job + * @param job + * Job Object for Job details + * @return job failure log message + * @throws IOException + * Can occur during fetching job status + * @throws InterruptedException + * Can occur during fetching job status + */ + public static String getJobFailureLogMessage(String name, Job job) + throws IOException, InterruptedException { + if (job != null) { + return String.format(JOB_FAILURE_LOG_FORMAT, name, job.getJobID(), + job.getStatus(), job.getStatus().getFailureInfo()); Review comment: Miss from my side! Done, thanks! -- 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. To unsubscribe, e-mail: dev-unsubscr...@nutch.apache.org For queries about this service, please contact Infrastructure at: us...@infra.apache.org