Skip to content

Commit

Permalink
Merge pull request #933 from metamx/removeDeprecatedFiles
Browse files Browse the repository at this point in the history
Update ForkingTaskRunner to remove @deprecated Files method usage
  • Loading branch information
fjy committed Dec 4, 2014
2 parents 2681da4 + 325a5c4 commit 6533de3
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -234,7 +234,7 @@ public TaskStatus call()
log.info("Logging task %s output to: %s", task.getId(), logFile);
boolean runFailed = true;

try (final OutputStream toLogfile = Files.newOutputStreamSupplier(logFile).getOutput()) {
try (final OutputStream toLogfile = Files.asByteSink(logFile).openBufferedStream()) {
ByteStreams.copy(processHolder.process.getInputStream(), toLogfile);
final int statusCode = processHolder.process.waitFor();
log.info("Process exited with status[%d] for task: %s", statusCode, task.getId());
Expand Down

0 comments on commit 6533de3

Please sign in to comment.