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

Config: Administrator config - max interval #843

Merged
merged 12 commits into from
Nov 4, 2024

Conversation

gtk-grafana
Copy link
Contributor

@gtk-grafana gtk-grafana commented Oct 21, 2024

Allow admins to optionally set a global maximum interval for Explore Logs.

Fixes: #842

image image

On changing time range to something with longer interval then maximum set in config:
image

@gtk-grafana
Copy link
Contributor Author

@JStickler the copy is still a bit clumsy: can you review when you have some time?

Input description copy:

  The maximum interval that can be selected in the time picker within the Explore Logs app. If empty users
              can select any time range interval in Explore Logs. <br />
              Example values: 7d, 24h, 2w

Toast copy:

Time range interval exceeds maximum interval configured by the administrator.

@matyax
Copy link
Contributor

matyax commented Oct 29, 2024

Can we display an error when it's not valid?

imagen

Similar to the date picker.

imagen

This also relates with the improvements after the upgrade of the data source configuration pages, where a huge part of the debt was due to missing error states or messages.

Copy link
Contributor

@matyax matyax left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks great! Left a few suggestions and minor comments. Great work!

src/Components/AppConfig/AppConfig.tsx Outdated Show resolved Hide resolved
src/Components/AppConfig/AppConfig.tsx Outdated Show resolved Hide resolved
src/Components/AppConfig/AppConfig.tsx Outdated Show resolved Hide resolved
src/Components/AppConfig/AppConfig.tsx Outdated Show resolved Hide resolved
src/Components/AppConfig/AppConfig.tsx Outdated Show resolved Hide resolved
src/Components/AppConfig/AppConfig.tsx Show resolved Hide resolved
src/Components/AppConfig/AppConfig.tsx Outdated Show resolved Hide resolved
src/Components/AppConfig/AppConfig.tsx Show resolved Hide resolved
src/Components/IndexScene/IndexScene.tsx Outdated Show resolved Hide resolved
@gtk-grafana
Copy link
Contributor Author

@matyax thank you for the excellent review, and good call on the error message:

image

@gtk-grafana gtk-grafana merged commit e9515e2 into main Nov 4, 2024
4 checks passed
@gtk-grafana gtk-grafana deleted the gtk-grafana/issues/842/config-max-timerange branch November 4, 2024 15:28
@gtk-grafana gtk-grafana self-assigned this Nov 4, 2024
@gtk-grafana gtk-grafana added this to the 1.0.3 milestone Nov 4, 2024
@gtk-grafana gtk-grafana added the enhancement New feature or request label Nov 4, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

Successfully merging this pull request may close these issues.

App Configuration: Set max time range
2 participants