mirror of https://github.com/apache/druid.git
Merge pull request #933 from metamx/removeDeprecatedFiles
Update ForkingTaskRunner to remove @Deprecated Files method usage
This commit is contained in:
commit
6533de3563
|
@ -234,7 +234,7 @@ public class ForkingTaskRunner implements TaskRunner, TaskLogStreamer
|
|||
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());
|
||||
|
|
Loading…
Reference in New Issue