diff --git a/indexing-service/src/main/java/io/druid/indexing/overlord/http/OverlordResource.java b/indexing-service/src/main/java/io/druid/indexing/overlord/http/OverlordResource.java index 050a5620856..76523504f53 100644 --- a/indexing-service/src/main/java/io/druid/indexing/overlord/http/OverlordResource.java +++ b/indexing-service/src/main/java/io/druid/indexing/overlord/http/OverlordResource.java @@ -412,9 +412,7 @@ public class OverlordResource try { final Optional stream = taskLogStreamer.streamTaskLog(taskid, offset); if (stream.isPresent()) { - try(InputStream istream = stream.get().openStream()) { - return Response.ok(istream).build(); - } + return Response.ok(stream.get().openStream()).build(); } else { return Response.status(Response.Status.NOT_FOUND) .entity(