use of com.thoughtworks.go.server.service.DiskSpaceChecker in project gocd by gocd.
the class GoDiskSpaceMonitor method onTimer.
//Note: This method is called from a Spring timer task
public void onTimer() {
OperationResult result = new DiskSpaceOperationResult(serverHealthService);
try {
boolean outOfDisk = false;
for (DiskSpaceChecker checker : checkers) {
OperationResult callResult = checker.resultFor(result);
checker.check(callResult);
outOfDisk = outOfDisk || !result.canContinue();
}
lowOnDisk = outOfDisk;
} catch (Exception e) {
LOG.error("Error occured during checking filesystems low disk space", e);
}
}
Aggregations