Skip to content

Commit

Permalink
try to fix opensearch-project#3962 catching exception
Browse files Browse the repository at this point in the history
  • Loading branch information
mbovo committed Jul 25, 2022
1 parent c0a5b6b commit dc1a00a
Showing 1 changed file with 1 addition and 4 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -460,10 +460,7 @@ private void onShardFailure(final int shardIndex, @Nullable SearchShardTarget sh
onPhaseFailure(this, "The phase has failed", ex);
}
} else if (totalOps > expectedTotalOps) {
throw new AssertionError(
"unexpected higher total ops [" + totalOps + "] compared to expected [" + expectedTotalOps + "]",
new SearchPhaseExecutionException(getName(), "Shard failures", null, buildShardFailures())
);
onPhaseFailure(this, "The phase has failed: unexpected higher total ops [" + totalOps + "] compared to expected [" + expectedTotalOps + "]", null);
} else {
if (lastShard == false) {
performPhaseOnShard(shardIndex, shardIt, nextShard);
Expand Down

0 comments on commit dc1a00a

Please sign in to comment.