Skip to content

Wire timeout flag to requests#129

Merged
timvisee merged 2 commits into
devfrom
wire-timeout-flag-to-requests
May 12, 2026
Merged

Wire timeout flag to requests#129
timvisee merged 2 commits into
devfrom
wire-timeout-flag-to-requests

Conversation

@agourlay
Copy link
Copy Markdown
Member

@agourlay agourlay commented May 12, 2026

Wire --timeout into per-request server-side timeouts

--timeout only configured the tonic channel deadline (client-side).

Qdrant aborts long operations using a separate per-request timeout field on the request payload, so against a slow on disk search the server returns a Timeout error before the channel deadline.

Thread args.timeout into every request builder that exposes a server-side .timeout():

  • QueryBatchPointsBuilder (main + search-quality exact) in src/search.rs
  • ScrollPointsBuilder in src/scroll.rs and src/query.rs
  • UpsertPointsBuilder and SetPayloadPointsBuilder in src/upsert.rs

Also added added a fixed 5-second cushion to the channel deadline so the server's structured timeout error reliably wins the race over the transport deadline.

Doc on --timeout updated to reflect the dual scope (channel deadline + server-side request timeout where supported).
Collection-management builders also expose .timeout() but are left untouched for this fix.

@agourlay agourlay requested review from M-Nawar, generall and timvisee May 12, 2026 11:08
@agourlay agourlay force-pushed the wire-timeout-flag-to-requests branch from bd0aa29 to c62cefb Compare May 12, 2026 12:24
@timvisee timvisee merged commit d0b9277 into dev May 12, 2026
3 checks passed
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