kfaraz commented on code in PR #16799:
URL: https://github.com/apache/druid/pull/16799#discussion_r1695257385


##########
indexing-service/src/main/java/org/apache/druid/indexing/overlord/http/OverlordResource.java:
##########
@@ -241,33 +241,32 @@ public Response isLeader()
     }
   }
 
-  @Deprecated
   @POST
-  @Path("/lockedIntervals")
+  @Path("/lockedIntervals/v2")
   @Produces(MediaType.APPLICATION_JSON)
   @ResourceFilters(StateResourceFilter.class)
-  public Response getDatasourceLockedIntervals(Map<String, Integer> 
minTaskPriority)
+  public Response getDatasourceLockedIntervals(List<LockFilterPolicy> 
lockFilterPolicies)
   {
-    if (minTaskPriority == null || minTaskPriority.isEmpty()) {
-      return Response.status(Status.BAD_REQUEST).entity("No Datasource 
provided").build();
+    if (lockFilterPolicies == null || lockFilterPolicies.isEmpty()) {
+      return Response.status(Status.BAD_REQUEST).entity("No filter 
provided").build();
     }
 
     // Build the response
-    return 
Response.ok(taskQueryTool.getLockedIntervals(minTaskPriority)).build();
+    return 
Response.ok(taskQueryTool.getLockedIntervals(lockFilterPolicies)).build();
   }
 
   @POST
-  @Path("/lockedIntervals/v2")
+  @Path("/activeLocks")
   @Produces(MediaType.APPLICATION_JSON)
   @ResourceFilters(StateResourceFilter.class)
-  public Response getDatasourceLockedIntervalsV2(List<LockFilterPolicy> 
lockFilterPolicies)
+  public Response getActiveLocks(List<LockFilterPolicy> lockFilterPolicies)

Review Comment:
   Super Nit: If you reverse the order of these two methods in this class file, 
the diff might become smaller/simpler. 🙂 
   (think of doing this only if you are fixing some other issue in this PR)



-- 
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...@druid.apache.org

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


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

Reply via email to