You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: packages/client-search/src/searchClient.ts
+12-9Lines changed: 12 additions & 9 deletions
Original file line number
Diff line number
Diff line change
@@ -251,15 +251,15 @@ export function createSearchClient({
251
251
* @param waitForTaskOptions - The `waitForTaskOptions` object.
252
252
* @param waitForTaskOptions.indexName - The `indexName` where the operation was performed.
253
253
* @param waitForTaskOptions.taskID - The `taskID` returned in the method response.
254
-
* @param waitForTaskOptions.maxRetries - The maximum number of retries. 50 by default.
254
+
* @param waitForTaskOptions.maxRetries - The maximum number of retries. 100 by default.
255
255
* @param waitForTaskOptions.timeout - The function to decide how long to wait between retries.
256
256
* @param requestOptions - The requestOptions to send along with the query, they will be forwarded to the `getTask` method and merged with the transporter requestOptions.
@@ -272,7 +272,8 @@ export function createSearchClient({
272
272
aggregator: ()=>(retryCount+=1),
273
273
error: {
274
274
validate: ()=>retryCount>=maxRetries,
275
-
message: ()=>`The maximum number of retries exceeded. (${retryCount}/${maxRetries})`,
275
+
message: ()=>
276
+
`Stopped waiting for the task after ${maxRetries} retries. This does not mean the operation failed; it may still complete. If you need to keep polling, retry with a higher maxRetries.`,
276
277
},
277
278
timeout: ()=>timeout(retryCount),
278
279
});
@@ -284,14 +285,14 @@ export function createSearchClient({
284
285
* @summary Helper method that waits for a task to be published (completed).
285
286
* @param waitForAppTaskOptions - The `waitForTaskOptions` object.
286
287
* @param waitForAppTaskOptions.taskID - The `taskID` returned in the method response.
287
-
* @param waitForAppTaskOptions.maxRetries - The maximum number of retries. 50 by default.
288
+
* @param waitForAppTaskOptions.maxRetries - The maximum number of retries. 100 by default.
288
289
* @param waitForAppTaskOptions.timeout - The function to decide how long to wait between retries.
289
290
* @param requestOptions - The requestOptions to send along with the query, they will be forwarded to the `getTask` method and merged with the transporter requestOptions.
@@ -304,7 +305,8 @@ export function createSearchClient({
304
305
aggregator: ()=>(retryCount+=1),
305
306
error: {
306
307
validate: ()=>retryCount>=maxRetries,
307
-
message: ()=>`The maximum number of retries exceeded. (${retryCount}/${maxRetries})`,
308
+
message: ()=>
309
+
`Stopped waiting for the task after ${maxRetries} retries. This does not mean the operation failed; it may still complete. If you need to keep polling, retry with a higher maxRetries.`,
308
310
},
309
311
timeout: ()=>timeout(retryCount),
310
312
});
@@ -318,7 +320,7 @@ export function createSearchClient({
318
320
* @param waitForApiKeyOptions.operation - The `operation` that was done on a `key`.
319
321
* @param waitForApiKeyOptions.key - The `key` that has been added, deleted or updated.
320
322
* @param waitForApiKeyOptions.apiKey - Necessary to know if an `update` operation has been processed, compare fields of the response with it.
321
-
* @param waitForApiKeyOptions.maxRetries - The maximum number of retries. 50 by default.
323
+
* @param waitForApiKeyOptions.maxRetries - The maximum number of retries. 100 by default.
322
324
* @param waitForApiKeyOptions.timeout - The function to decide how long to wait between retries.
323
325
* @param requestOptions - The requestOptions to send along with the query, they will be forwarded to the `getApikey` method and merged with the transporter requestOptions.
324
326
*/
@@ -327,7 +329,7 @@ export function createSearchClient({
@@ -337,7 +339,8 @@ export function createSearchClient({
337
339
aggregator: ()=>(retryCount+=1),
338
340
error: {
339
341
validate: ()=>retryCount>=maxRetries,
340
-
message: ()=>`The maximum number of retries exceeded. (${retryCount}/${maxRetries})`,
342
+
message: ()=>
343
+
`Stopped waiting for the API key operation after ${maxRetries} retries. This does not mean the operation failed; it may still complete. If you need to keep polling, retry with a higher maxRetries.`,
Copy file name to clipboardExpand all lines: packages/composition/src/compositionClient.ts
+4-3Lines changed: 4 additions & 3 deletions
Original file line number
Diff line number
Diff line change
@@ -165,15 +165,15 @@ export function createCompositionClient({
165
165
* @param WaitForCompositionTaskOptions - The `WaitForCompositionTaskOptions` object.
166
166
* @param WaitForCompositionTaskOptions.compositionID - The `compositionID` where the operation was performed.
167
167
* @param WaitForCompositionTaskOptions.taskID - The `taskID` returned in the method response.
168
-
* @param WaitForCompositionTaskOptions.maxRetries - The maximum number of retries. 50 by default.
168
+
* @param WaitForCompositionTaskOptions.maxRetries - The maximum number of retries. 100 by default.
169
169
* @param WaitForCompositionTaskOptions.timeout - The function to decide how long to wait between retries.
170
170
* @param requestOptions - The requestOptions to send along with the query, they will be forwarded to the `getTask` method and merged with the transporter requestOptions.
@@ -186,7 +186,8 @@ export function createCompositionClient({
186
186
aggregator: ()=>(retryCount+=1),
187
187
error: {
188
188
validate: ()=>retryCount>=maxRetries,
189
-
message: ()=>`The maximum number of retries exceeded. (${retryCount}/${maxRetries})`,
189
+
message: ()=>
190
+
`Stopped waiting for the task after ${maxRetries} retries. This does not mean the operation failed; it may still complete. If you need to keep polling, retry with a higher maxRetries.`,
0 commit comments