diff --git a/azkaban-execserver/src/main/java/azkaban/execapp/JobRunner.java b/azkaban-execserver/src/main/java/azkaban/execapp/JobRunner.java
index 3492330..c2ed6d5 100644
--- a/azkaban-execserver/src/main/java/azkaban/execapp/JobRunner.java
+++ b/azkaban-execserver/src/main/java/azkaban/execapp/JobRunner.java
@@ -359,7 +359,7 @@ public class JobRunner extends EventHandler implements Runnable {
return false;
}
- private void finalizeLogFile() {
+ private void finalizeLogFile(int attemptNo) {
closeLogger();
if (logFile == null) {
flowLogger.info("Log file for job " + this.jobId + " is null");
@@ -375,8 +375,8 @@ public class JobRunner extends EventHandler implements Runnable {
});
Arrays.sort(files, Collections.reverseOrder());
- loader.uploadLogFile(executionId, this.node.getNestedId(),
- node.getAttempt(), files);
+ loader.uploadLogFile(executionId, this.node.getNestedId(), attemptNo,
+ files);
} catch (ExecutorManagerException e) {
flowLogger.error(
"Error writing out logs for job " + this.node.getNestedId(), e);
@@ -456,11 +456,13 @@ public class JobRunner extends EventHandler implements Runnable {
// it being a legitimate failure.
changeStatus(Status.KILLED);
}
- logInfo("Finishing job " + this.jobId + " at " + node.getEndTime()
- + " with status " + node.getStatus());
+
+ int attemptNo = node.getAttempt();
+ logInfo("Finishing job " + this.jobId + " attempt: " + attemptNo + " at "
+ + node.getEndTime() + " with status " + node.getStatus());
fireEvent(Event.create(this, Type.JOB_FINISHED), false);
- finalizeLogFile();
+ finalizeLogFile(attemptNo);
finalizeAttachmentFile();
writeStatus();
}
diff --git a/azkaban-execserver/src/main/java/azkaban/execapp/ProjectVersion.java b/azkaban-execserver/src/main/java/azkaban/execapp/ProjectVersion.java
index 35efc24..0afc7f8 100644
--- a/azkaban-execserver/src/main/java/azkaban/execapp/ProjectVersion.java
+++ b/azkaban-execserver/src/main/java/azkaban/execapp/ProjectVersion.java
@@ -26,7 +26,6 @@ import org.apache.log4j.Logger;
import azkaban.project.ProjectFileHandler;
import azkaban.project.ProjectLoader;
import azkaban.project.ProjectManagerException;
-
import azkaban.utils.FileIOUtils;
import azkaban.utils.Utils;
@@ -95,9 +94,11 @@ public class ProjectVersion implements Comparable<ProjectVersion> {
public synchronized void copyCreateSymlinkDirectory(File executionDir)
throws IOException {
if (installedDir == null || !installedDir.exists()) {
- throw new IOException("Installed dir doesn't exist");
+ throw new IOException("Installed dir doesn't exist: "
+ + ((installedDir == null) ? null : installedDir.getAbsolutePath()));
} else if (executionDir == null || !executionDir.exists()) {
- throw new IOException("Execution dir doesn't exist");
+ throw new IOException("Execution dir doesn't exist: "
+ + ((executionDir == null) ? null : executionDir.getAbsolutePath()));
}
FileIOUtils.createDeepSymlink(installedDir, executionDir);
}