@algolia/client-search 5.54.1 → 5.55.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -5,6 +5,7 @@ import { createFetchRequester } from "@algolia/requester-fetch";
5
5
  // src/searchClient.ts
6
6
  import {
7
7
  ApiError,
8
+ DEFAULT_REPLACE_ALL_OBJECTS_MAX_RETRIES,
8
9
  createAuth,
9
10
  createIterablePromise,
10
11
  createTransporter,
@@ -12,7 +13,7 @@ import {
12
13
  shuffle,
13
14
  validateRequired
14
15
  } from "@algolia/client-common";
15
- var apiClientVersion = "5.54.1";
16
+ var apiClientVersion = "5.55.1";
16
17
  function getDefaultHosts(appId) {
17
18
  return [
18
19
  {
@@ -453,10 +454,16 @@ function createSearchClient({
453
454
  * @param replaceAllObjects.objects - The array of `objects` to store in the given Algolia `indexName`.
454
455
  * @param replaceAllObjects.batchSize - The size of the chunk of `objects`. The number of `batch` calls will be equal to `objects.length / batchSize`. Defaults to 1000.
455
456
  * @param replaceAllObjects.scopes - The `scopes` to keep from the index. Defaults to ['settings', 'rules', 'synonyms'].
456
- * @param replaceAllObjects.maxRetries - The maximum number of retries when polling for task completion. 100 by default.
457
+ * @param replaceAllObjects.maxRetries - The maximum number of retries when polling for task completion. 800 by default.
457
458
  * @param requestOptions - The requestOptions to send along with the query, they will be forwarded to the `batch`, `operationIndex` and `getTask` method and merged with the transporter requestOptions.
458
459
  */
459
- async replaceAllObjects({ indexName, objects, batchSize, scopes, maxRetries = 100 }, requestOptions) {
460
+ async replaceAllObjects({
461
+ indexName,
462
+ objects,
463
+ batchSize,
464
+ scopes,
465
+ maxRetries = DEFAULT_REPLACE_ALL_OBJECTS_MAX_RETRIES
466
+ }, requestOptions) {
460
467
  const randomSuffix = Math.floor(Math.random() * 1e6) + 1e5;
461
468
  const tmpIndexName = `${indexName}_tmp_${randomSuffix}`;
462
469
  if (scopes === void 0) {