Skip to content

Commit

Permalink
catch exception other than APIException
Browse files Browse the repository at this point in the history
  • Loading branch information
Zhun Xu committed Oct 28, 2019
1 parent 0f6a531 commit 214c684
Showing 1 changed file with 8 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -523,6 +523,14 @@ private SeldonMessage queryREST(
logger.error("Invalid protocol buffer during Json Format merge - ", e);
throw new APIException(
APIException.ApiExceptionType.ENGINE_MICROSERVICE_ERROR, e.toString());
} catch (APIException e)
{
throw e;
} catch (Exception e)
{
logger.error("Couldn't retrieve prediction from external prediction server - ", e);
throw new APIException(
APIException.ApiExceptionType.ENGINE_MICROSERVICE_ERROR, e.toString());
}
}
logger.error("Failed to retrueve predictions after {} attempts", restRetries);
Expand Down

0 comments on commit 214c684

Please sign in to comment.