gortiz commented on code in PR #15180:
URL: https://github.com/apache/pinot/pull/15180#discussion_r1991929614


##########
pinot-broker/src/main/java/org/apache/pinot/broker/api/resources/PinotClientRequest.java:
##########
@@ -398,20 +399,22 @@ public String cancelQuery(
       @DefaultValue("3000") int timeoutMs,
       @ApiParam(value = "Return server responses for troubleshooting") 
@QueryParam("verbose") @DefaultValue("false")
       boolean verbose) {
-    try {
+    try (QueryThreadContext.CloseableContext closeMe = 
QueryThreadContext.open()) {
+      long reqId = Long.parseLong(id);
+      QueryThreadContext.setIds(reqId, id);

Review Comment:
   You are right. In fact, the code this morning was different, but it looked a 
bit strange to only set the ids in one of the branches. I changed the code to 
make it easier to read. Now the broker handlers have a method to return the 
request id given a client id and in case it is not  found we use a default 
value instead.



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscr...@pinot.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscr...@pinot.apache.org
For additional commands, e-mail: commits-h...@pinot.apache.org

Reply via email to