Skip to content

Commit 91cee0f

Browse files
authored
🐛 fix for large files timing out in async mode (#218)
1 parent eced0d3 commit 91cee0f

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

src/main/java/com/mindee/AsyncPollingOptions.java

+1-1
Original file line numberDiff line numberDiff line change
@@ -29,6 +29,6 @@ private AsyncPollingOptions(
2929
) {
3030
this.initialDelaySec = initialDelaySec == null ? 2.0 : initialDelaySec;
3131
this.intervalSec = intervalSec == null ? 1.5 : intervalSec;
32-
this.maxRetries = maxRetries == null ? 30 : maxRetries;
32+
this.maxRetries = maxRetries == null ? 40 : maxRetries;
3333
}
3434
}

src/main/java/com/mindee/MindeeClient.java

+1-1
Original file line numberDiff line numberDiff line change
@@ -380,7 +380,7 @@ private <T extends Inference> AsyncPredictResponse<T> enqueueAndParse(
380380
retryCount++;
381381
Thread.sleep(intervalSec);
382382
}
383-
throw new RuntimeException("Max retries exceeded. Failed to get the document.");
383+
throw new RuntimeException("Max retries exceeded: " + retryCount +". Failed to get the document.");
384384
}
385385

386386
/**

0 commit comments

Comments
 (0)