Skip to content

Commit 64fb483

Browse files
committed
add more comments
Signed-off-by: Xun Zhang <xunzh@amazon.com>
1 parent 4a726f2 commit 64fb483

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

ml-algorithms/src/main/java/org/opensearch/ml/engine/algorithms/remote/MLSdkAsyncHttpResponseHandler.java

+2
Original file line numberDiff line numberDiff line change
@@ -109,6 +109,8 @@ private void handleThrottlingInHeader(SdkHttpFullResponse sdkResponse) {
109109
if (errorsInHeader == null || errorsInHeader.isEmpty()) {
110110
return;
111111
}
112+
// Check the throttling exception from AMZN servers, e.g. sageMaker.
113+
// See [https://github.com/opensearch-project/ml-commons/issues/2429] for more details.
112114
boolean containsThrottlingException = errorsInHeader.stream().anyMatch(str -> str.startsWith("ThrottlingException"));
113115
if (containsThrottlingException && executionContext.getExceptionHolder().get() == null) {
114116
log.error("Remote server returned error code: {}", statusCode);

0 commit comments

Comments
 (0)