scylla-rust-driver icon indicating copy to clipboard operation
scylla-rust-driver copied to clipboard

Decouple schema fetch queries from server-side timeouts

Open dkropachev opened this issue 1 year ago • 0 comments

Details

If the user set server-side timeouts, or service level timeouts, this impacts schema fetches. The timeout can be too low to allow a schema fetch when the schema is very large.

Instead, qualify schema (and other metadata) fetches with USING TIMEOUT (with a high and configurable default) so schema fetches work regardless of timeout tuning.

Core issue: https://github.com/scylladb/scylladb/issues/18471

Limitations

  1. USING TIMEOUT is not supported by cassandra and support by all major scylla versions, so it is safe to assume it is supported by seeing scylla-specific metadata.
  2. Minimal supported scale is ms, so statement suffix should look like this: USING TIMEOUT {timeout_in_ms} ms

Requirements

  1. Timeout should be configurable and default should be 2s
  2. 0 signals that feature is disabled

dkropachev avatar Aug 04 '24 17:08 dkropachev