Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Configurable CQL query timeouts by query type #783

Closed
jeffreyscarpenter opened this issue Jan 10, 2024 · 1 comment · Fixed by #785
Closed

Configurable CQL query timeouts by query type #783

jeffreyscarpenter opened this issue Jan 10, 2024 · 1 comment · Fixed by #785
Assignees

Comments

@jeffreyscarpenter
Copy link
Contributor

Currently the JSON API only supports a single configurable value for CQL query timeouts, which defaults to 10s in the standard config file that is checked in.

At high scale usage in cloud environments, we've observed the need for more flexible controls for different types of queries. For example, DDL queries like create/delete table have different behavior and can take longer in cloud environments.

JSON API can make use of the execution profile feature offered by the CQL in order to create profiles for each type of query, with separate timeouts for each profile. This will allow users to have more flexible control over timeouts with a simple config file change.

Suggested profiles:

  • default (use for DML that doesn't include LWT)
  • lwt (use for DML that includes LWT)
  • schema (DDL such as create/delete table)
  • count (use for SELECT COUNT queries)
@jeffreyscarpenter
Copy link
Contributor Author

We might also be able to use a count profile to disable CQL warning logs for COUNT statements only, to get rid of these annoying log messages

Query '[0 values] SELECT COUNT(1) AS count FROM my_namespace.my_collection' generated server side warning(s): Aggregation query used without partition key

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 a pull request may close this issue.

2 participants