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] Default window size is not a valid window size #155

Closed
deshsidd opened this issue Nov 12, 2024 · 0 comments · Fixed by #156
Closed

[BUG] Default window size is not a valid window size #155

deshsidd opened this issue Nov 12, 2024 · 0 comments · Fixed by #156
Labels
bug Something isn't working untriaged

Comments

@deshsidd
Copy link
Collaborator

What is the bug?

The default window size for latency, cpu and memory is 60s hardcoded on the backend:

public static final TimeValue DEFAULT_WINDOW_SIZE = new TimeValue(60, TimeUnit.SECONDS);

The valid window sizes are defined as:

public static final Set<TimeValue> VALID_WINDOW_SIZES_IN_MINUTES = new HashSet<>(
        Arrays.asList(
            new TimeValue(1, TimeUnit.MINUTES),
            new TimeValue(5, TimeUnit.MINUTES),
            new TimeValue(10, TimeUnit.MINUTES),
            new TimeValue(30, TimeUnit.MINUTES)
        )
    );

The default window size is not a valid window size based on the above.

This will break the QI dashboard since the dashboard only parses timeunit m and h:
https://github.com/opensearch-project/query-insights-dashboards/blob/main/public/pages/TopNQueries/TopNQueries.tsx#L192

How can one reproduce the bug?

Steps to reproduce the behavior.

What is the expected behavior?

A clear and concise description of what you expected to happen.

What is your host/environment?

Operating system, version.

Do you have any screenshots?

If applicable, add screenshots to help explain your problem.

Do you have any additional context?

Add any other context about the problem.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working untriaged
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant