vrajat commented on code in PR #14451:
URL: https://github.com/apache/pinot/pull/14451#discussion_r1862165234


##########
pinot-controller/src/main/java/org/apache/pinot/controller/api/resources/PinotSegmentRestletResource.java:
##########
@@ -891,6 +892,31 @@ public String getTableReloadMetadata(
     }
   }
 
+  @GET
+  @Path("segments/{tableNameWithType}/needRefresh")
+  @Authorize(targetType = TargetType.TABLE, paramName = "tableNameWithType", 
action = Actions.Table.GET_METADATA)
+  @Produces(MediaType.APPLICATION_JSON)
+  @ApiOperation(value = "Gets a list of segments that need to be refreshed 
from servers hosting the table", notes =
+      "Gets a list of segments that need to be refreshed from servers hosting 
the table")
+  public Map<String, List<NeedRefreshResponse>> getTableRefreshMetadata(

Review Comment:
   I have added an explicit class that tracks server -> response. The response 
also has an error message. Using null to denote error was icky. Check 
`TableStaleSegmentResponse`



-- 
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: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to