npawar commented on a change in pull request #5718: URL: https://github.com/apache/incubator-pinot/pull/5718#discussion_r459165596
########## File path: pinot-controller/src/main/java/org/apache/pinot/controller/api/resources/PinotSegmentRestletResource.java ########## @@ -246,21 +268,7 @@ return segmentMetadata; } else { throw new ControllerApplicationException(LOGGER, - "Failed to find segment: " + segmentName + " in table: " + tableName, Status.NOT_FOUND); - } - } - - @Nullable Review comment: i could spot no change in this method vs same method moved at the bottom. can we keep it here, so that the scope of review stays limited to the actual changes? ########## File path: pinot-controller/src/main/java/org/apache/pinot/controller/api/resources/PinotSegmentRestletResource.java ########## @@ -128,20 +137,33 @@ @Api(tags = Constants.SEGMENT_TAG) @Path("/") public class PinotSegmentRestletResource { - private static Logger LOGGER = LoggerFactory.getLogger(PinotSegmentRestletResource.class); + private static final Logger LOGGER = LoggerFactory.getLogger(PinotSegmentRestletResource.class); + + @Inject + ControllerConf _controllerConf; @Inject PinotHelixResourceManager _pinotHelixResourceManager; + @Inject + Executor _executor; + + @Inject + HttpConnectionManager _connectionManager; + + @Inject + ControllerMetrics _controllerMetrics; + + @GET @Produces(MediaType.APPLICATION_JSON) @Path("/segments/{tableName}") @ApiOperation(value = "List all segments", notes = "List all segments") public List<Map<TableType, List<String>>> getSegments( - @ApiParam(value = "Name of the table", required = true) @PathParam("tableName") String tableName, - @ApiParam(value = "OFFLINE|REALTIME") @QueryParam("type") String tableTypeStr) { + @ApiParam(value = "Name of the table", required = true) @PathParam("tableName") String tableName, Review comment: there seems to be some unnecessary formatting/whitespaces on all methods of this file. Could you revert those? you should be able to auto-format using the IDE same comment for TablesResourceTest file ---------------------------------------------------------------- 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. 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