Skip to content

fix(clients): bump replaceAllObjects default maxRetries from 100 to 800 - #6580

Merged
Fluf22 merged 3 commits into
mainfrom
fix/rao-default-retries
Jun 22, 2026
Merged

Fluf22 merged 3 commits into
mainfrom
fix/rao-default-retries

Conversation

@Fluf22

@Fluf22 Fluf22 commented Jun 17, 2026 •

Copy link
Copy Markdown
Collaborator

Summary

Raises the default maxRetries for the replaceAllObjects helper from 100 to 800 across all 11 language clients. replaceAllObjects copies and moves entire indices and waits on potentially long-running tasks, so it needs a higher polling budget than the standard helpers.

Scope — replaceAllObjects only

  • New constant DEFAULT_REPLACE_ALL_OBJECTS_MAX_RETRIES = 800 (one per language) is used as the default maxRetries for replaceAllObjects and replaceAllObjectsWithTransformation only.
  • It is threaded through the whole RAO operation: the internal chunked batch/push and the copy/copy/move task-completion waits.
  • Unchanged at 100: saveObjects, deleteObjects, partialUpdateObjects, chunkedBatch, chunkedPush, and the standalone waitForTask / waitForAppTask / waitForApiKey helpers — their ChunkedHelperOptions default is untouched.

Languages

JavaScript, Python, Java, Go, Ruby, PHP, Kotlin, Scala, Swift, Dart, C#.

Notes

  • Source-only change (Mustache templates + hand-written helper files). Generated clients are produced by CI.
  • A CTS test covering the RAO retry behavior is deferred to a follow-up: CTS uses exact per-language error-string matching for retry exhaustion, which needs a real CTS run to verify reliably.

Introduce a DEFAULT_REPLACE_ALL_OBJECTS_MAX_RETRIES (800) constant per language and use it as the default maxRetries for replaceAllObjects and replaceAllObjectsWithTransformation only. It is threaded through the internal batch and the copy/move task-completion waits.

All other chunked helpers (saveObjects, deleteObjects, partialUpdateObjects, chunkedBatch, chunkedPush) and the standalone waitForTask/waitForAppTask/waitForApiKey helpers keep their existing default of 100.

Source-only change; generated clients are regenerated by CI.
@algolia-api-clients-automation-bot

algolia-api-clients-automation-bot Bot commented Jun 17, 2026 •

Copy link
Copy Markdown
Contributor

✔️ Code generated!

Name Link
🪓 Triggered by 9f63ea623c3f78e09d1532ccc75a21fa9eb33c6a
🍃 Generated commit 45bde95e6c1df508d85748bae4cf711a5cd4296d
🌲 Generated branch generated/fix/rao-default-retries
📊 Benchmark results

Benchmarks performed on the method using a mock server, the results might not reflect the real-world performance.

Language Req/s
javascript 2242
go 1908
php 1811
python 1273
csharp 1251
java 1097
ruby 969
swift 328
scala 23

Fluf22 added 2 commits June 18, 2026 09:36
…per docstrings

The replaceAllObjects / replaceAllObjectsWithTransformation default maxRetries is now 800, not 100.
@Fluf22
Fluf22 marked this pull request as ready for review June 18, 2026 17:53
@Fluf22
Fluf22 requested a review from a team as a code owner June 18, 2026 17:53
@Fluf22
Fluf22 merged commit a676cd9 into main Jun 22, 2026
36 checks passed
@Fluf22
Fluf22 deleted the fix/rao-default-retries branch June 22, 2026 09:08
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants