Skip to content

Commit b067f54

Browse files
committed
Added comment
1 parent 6b708d1 commit b067f54

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

x-pack/plugin/inference/src/main/java/org/elasticsearch/xpack/inference/queries/SemanticQueryBuilder.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -218,7 +218,7 @@ private QueryBuilder doRewriteBuildSemanticQuery(SearchExecutionContext searchEx
218218
case ErrorInferenceResults errorInferenceResults -> throw new InferenceException(
219219
"Field [" + fieldName + "] with inference ID [" + inferenceId + "] query inference error",
220220
errorInferenceResults.getException()
221-
);
221+
); // Use InferenceException here so that the status code is set by the cause
222222
case WarningInferenceResults warningInferenceResults -> throw new IllegalStateException(
223223
"Field ["
224224
+ fieldName

0 commit comments

Comments
 (0)