From 4681ff22ed261459e5c0f2d4240db353ab31ecfd Mon Sep 17 00:00:00 2001 From: Nishant Date: Thu, 10 Sep 2015 13:45:20 +0530 Subject: [PATCH] add task duration in response for completed tasks --- .../java/io/druid/indexing/overlord/http/OverlordResource.java | 3 +++ 1 file changed, 3 insertions(+) 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 a3cb1e75232..c4307c533ac 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 @@ -539,6 +539,9 @@ public class OverlordResource } if (status.isPresent()) { data.put("statusCode", status.get().getStatusCode().toString()); + if(status.get().isComplete()) { + data.put("duration", status.get().getDuration()); + } } return data; }