jihaozh commented on a change in pull request #4322: [TE] detection health status URL: https://github.com/apache/incubator-pinot/pull/4322#discussion_r294971266
########## File path: thirdeye/thirdeye-pinot/src/main/java/org/apache/pinot/thirdeye/detection/DetectionResource.java ########## @@ -562,4 +564,19 @@ public Response getPredictedBaseline( return Response.ok(baselineTimeseries).build(); } + + @GET + @Path(value = "/health/{id}") + @ApiOperation("Get the detection health metrics and statuses for a detection config") + public Response getDetectionHealth(@PathParam("id") @ApiParam("detection config id") long id, + @ApiParam("Start time for the the health metric") @QueryParam("start") long start, + @ApiParam("End time for the the health metric") @QueryParam("end") long end, + @ApiParam("Max number of detection tasks returned") @QueryParam("limit") @DefaultValue("500") long limit) throws JsonProcessingException { + DetectionHealth health = new DetectionHealth.Builder(id, start, end).addRegressionStatus(this.evaluationDAO) Review comment: Added the try-catch ---------------------------------------------------------------- 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 With regards, Apache Git Services --------------------------------------------------------------------- To unsubscribe, e-mail: commits-unsubscr...@pinot.apache.org For additional commands, e-mail: commits-h...@pinot.apache.org