Skip to content

Commit

Permalink
Merge pull request #1983 from batmat/JENKINS-26466-decouple-AbstractP…
Browse files Browse the repository at this point in the history
…roject-from-DiskSpaceMonitor

[JENKINS-26466] Decouple AbstractProject from DiskSpaceMonitor
  • Loading branch information
olivergondza committed Jan 30, 2016
2 parents 452b6fd + dad9cb6 commit 59540fa
Showing 1 changed file with 1 addition and 8 deletions.
9 changes: 1 addition & 8 deletions core/src/main/java/hudson/model/AbstractProject.java
Expand Up @@ -55,7 +55,6 @@
import hudson.model.queue.QueueTaskFuture;
import hudson.model.queue.SubTask;
import hudson.model.queue.SubTaskContributor;
import hudson.node_monitors.DiskSpaceMonitor;
import hudson.scm.ChangeLogSet;
import hudson.scm.ChangeLogSet.Entry;
import hudson.scm.NullSCM;
Expand Down Expand Up @@ -1265,13 +1264,7 @@ public boolean checkout(AbstractBuild build, Launcher launcher, BuildListener li
return true; // no SCM

FilePath workspace = build.getWorkspace();
try {
workspace.mkdirs();
} catch (IOException e) {
// Can't create workspace dir - Is slave disk full ?
new DiskSpaceMonitor().markNodeOfflineIfDiskspaceIsTooLow(build.getBuiltOn().toComputer());
throw e;
}
workspace.mkdirs();

boolean r = scm.checkout(build, launcher, workspace, listener, changelogFile);
if (r) {
Expand Down

0 comments on commit 59540fa

Please sign in to comment.