Skip to content

Commit

Permalink
Update plugin/src/main/java/org/opensearch/ml/action/handler/MLSearch…
Browse files Browse the repository at this point in the history
…Handler.java

Co-authored-by: Hailong Cui <[email protected]>
Signed-off-by: samuel-oci <[email protected]>
  • Loading branch information
sam-herman and Hailong-am authored Jan 12, 2024
1 parent 8db913e commit 091c47c
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -202,7 +202,7 @@ private QueryBuilder rewriteQueryBuilder(QueryBuilder queryBuilder, List<String>
public static <T> ActionListener<T> wrapRestActionListener(ActionListener<T> actionListener, String generalErrorMessage) {
return ActionListener.<T>wrap(r -> { actionListener.onResponse(r); }, e -> {
log.error("Wrap exception before sending back to user", e);
Throwable cause = ExceptionUtils.getRootCause(e);
Throwable cause = org.opensearch.ExceptionsHelper.unwrap(e);
if (isProperExceptionToReturn(e)) {
actionListener.onFailure(e);
} else if (isProperExceptionToReturn(cause)) {
Expand Down

0 comments on commit 091c47c

Please sign in to comment.