You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@pinot.apache.org by "deemoliu (via GitHub)" <gi...@apache.org> on 2023/06/29 00:11:25 UTC

[GitHub] [pinot] deemoliu commented on a diff in pull request #10758: Add a new controller endpoint for segment deletion with a time window

deemoliu commented on code in PR #10758:
URL: https://github.com/apache/pinot/pull/10758#discussion_r1245918886


##########
pinot-controller/src/main/java/org/apache/pinot/controller/api/resources/PinotSegmentRestletResource.java:
##########
@@ -884,6 +865,52 @@ public SuccessResponse deleteSegments(
     }
   }
 
+  @DELETE
+  @Consumes(MediaType.APPLICATION_JSON)
+  @Produces(MediaType.APPLICATION_JSON)
+  @Path("/segments/{tableName}/select")
+  @Authenticate(AccessType.DELETE)
+  @ApiOperation(value = "Delete select segments. An optional 'excludeReplacedSegments' parameter is used to get the"

Review Comment:
   select --> selected segments



##########
pinot-controller/src/main/java/org/apache/pinot/controller/api/resources/PinotSegmentRestletResource.java:
##########
@@ -884,6 +865,52 @@ public SuccessResponse deleteSegments(
     }
   }
 
+  @DELETE
+  @Consumes(MediaType.APPLICATION_JSON)
+  @Produces(MediaType.APPLICATION_JSON)
+  @Path("/segments/{tableName}/select")
+  @Authenticate(AccessType.DELETE)
+  @ApiOperation(value = "Delete select segments. An optional 'excludeReplacedSegments' parameter is used to get the"
+      + " list of segments which has not yet been replaced (determined by segment lineage entries) and can be queried"
+      + " from the table. The value is false by default.",
+      // TODO: more and more filters can be added later on, like excludeErrorSegments, excludeConsumingSegments, etc.
+      notes = "List all segments")
+  public SuccessResponse deleteSegmentsWithTimeWindow(
+      @ApiParam(value = "Name of the table", required = true) @PathParam("tableName") String tableName,
+      @ApiParam(value = "OFFLINE|REALTIME") @QueryParam("type") String tableTypeStr,

Review Comment:
   should this be required? do we have a default value for this? 
   if not, how does it work for hybrid tables?



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

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


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