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

[BUG] Rollups - SearchRequest missing cancelAfterTimeInterval parameter #710

Closed
petardz opened this issue Mar 6, 2023 · 4 comments
Closed
Assignees
Labels
bug Something isn't working good first issue Good for newcomers rollup tiny

Comments

@petardz
Copy link
Contributor

petardz commented Mar 6, 2023

What is the bug?
In RollupRunner we don't set cancelAfterTimeInterval parameter on SearchRequest object. Consequence of this is that global cluster setting search.cancel_after_time_interval will override it, which if set too low, could impact rollup run success rate.

How can one reproduce the bug?
Steps to reproduce the behavior:

  1. Set cluster setting search.cancel_after_time_interval to something very low, like 1s
  2. Create rollup job on index with some number of documents/shards
  3. See Cancellation timeout error (TaskCancelledExceptioncancelled exception)

What is the expected behavior?
Rollup job should have full control of this timeout.

@petardz petardz added bug Something isn't working untriaged labels Mar 6, 2023
@rishabhmaurya
Copy link
Contributor

Are you proposing its resolution to be individual plugin's responsibility to set the search.cancel_after_time_interval with max(cluster setting search.cancel_after_time_interval, plugin's default minimum value say 5s) ?

@petardz
Copy link
Contributor Author

petardz commented Mar 8, 2023

@rishabhmaurya If I understood correctly, cluster setting search.cancel_after_time_interval will be used only if same param in SearchRequest is null?

If that's the case, then plugin can override this setting by setting a cancelAfterTimeInterval param in every SearchRequest before calling _search. For rollups and transforms I'd say to give it at least 10m.

@rishabhmaurya
Copy link
Contributor

relates to - opensearch-project/alerting#827

@Joshua152
Copy link
Contributor

Can I be assigned to this issue?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working good first issue Good for newcomers rollup tiny
Projects
Status: Done
Development

No branches or pull requests

4 participants