From 39203009009cc25d4d0f4d142801a22938475bd6 Mon Sep 17 00:00:00 2001 From: fjy Date: Tue, 29 Jul 2014 21:44:07 -0700 Subject: [PATCH] fix router bug --- .../java/io/druid/server/AsyncQueryForwardingServlet.java | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/server/src/main/java/io/druid/server/AsyncQueryForwardingServlet.java b/server/src/main/java/io/druid/server/AsyncQueryForwardingServlet.java index f284a276202..91f90d37f91 100644 --- a/server/src/main/java/io/druid/server/AsyncQueryForwardingServlet.java +++ b/server/src/main/java/io/druid/server/AsyncQueryForwardingServlet.java @@ -49,6 +49,7 @@ import javax.servlet.http.HttpServletResponse; import java.io.IOException; import java.net.URI; import java.util.Enumeration; +import java.util.UUID; import java.util.concurrent.TimeUnit; /** @@ -116,6 +117,9 @@ public class AsyncQueryForwardingServlet extends AsyncProxyServlet inputQuery = objectMapper.readValue(request.getInputStream(), Query.class); if (inputQuery != null) { host = hostFinder.getHost(inputQuery); + if (inputQuery.getId() == null) { + inputQuery = inputQuery.withId(UUID.randomUUID().toString()); + } } } catch (IOException e) {