-
Notifications
You must be signed in to change notification settings - Fork 12.3k
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
Alerting: Add alert instance picker #67138
Merged
Merged
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
soniaAguilarPeiron
force-pushed
the
alerting/templates-preview
branch
2 times, most recently
from
April 25, 2023 10:25
15696fd
to
b50bdb4
Compare
VikaCep
force-pushed
the
alerting/templates-preview-instance-picker
branch
2 times, most recently
from
April 25, 2023 22:01
129ada7
to
183ede6
Compare
public/app/features/alerting/unified/components/receivers/AlertInstanceModalSelector.tsx
Outdated
Show resolved
Hide resolved
public/app/features/alerting/unified/components/receivers/AlertInstanceModalSelector.tsx
Show resolved
Hide resolved
I reviewed and tested locally and it looks great @VikaCep ! 🙌 |
VikaCep
force-pushed
the
alerting/templates-preview-instance-picker
branch
from
April 26, 2023 20:02
2f9e51e
to
93f0f3d
Compare
VikaCep
added
no-backport
Skip backport of PR
no-changelog
Skip including change in changelog/release notes
labels
Apr 26, 2023
konrad147
reviewed
Apr 27, 2023
public/app/features/alerting/unified/components/receivers/AlertInstanceModalSelector.tsx
Outdated
Show resolved
Hide resolved
public/app/features/alerting/unified/components/receivers/AlertInstanceModalSelector.tsx
Outdated
Show resolved
Hide resolved
public/app/features/alerting/unified/components/receivers/AlertInstanceModalSelector.tsx
Outdated
Show resolved
Hide resolved
public/app/features/alerting/unified/components/receivers/AlertInstanceModalSelector.tsx
Outdated
Show resolved
Hide resolved
soniaAguilarPeiron
force-pushed
the
alerting/templates-preview
branch
2 times, most recently
from
April 27, 2023 13:39
5f4463c
to
6c9206c
Compare
VikaCep
force-pushed
the
alerting/templates-preview-instance-picker
branch
from
April 27, 2023 13:45
93f0f3d
to
0ae8c93
Compare
soniaAguilarPeiron
approved these changes
Apr 27, 2023
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM! 🚀🎉
konrad147
approved these changes
Apr 28, 2023
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Nice! 🚀 I left one non-blocking nit
public/app/features/alerting/unified/components/receivers/AlertInstanceModalSelector.tsx
Outdated
Show resolved
Hide resolved
public/app/features/alerting/unified/components/receivers/AlertInstanceModalSelector.tsx
Show resolved
Hide resolved
soniaAguilarPeiron
force-pushed
the
alerting/templates-preview
branch
from
April 28, 2023 10:58
c7d112c
to
4d57f98
Compare
VikaCep
force-pushed
the
alerting/templates-preview-instance-picker
branch
from
April 28, 2023 12:24
5020065
to
c38de10
Compare
VikaCep
added
add to changelog
add to what's new
and removed
no-changelog
Skip including change in changelog/release notes
labels
Apr 28, 2023
ryantxu
pushed a commit
that referenced
this pull request
May 3, 2023
* Add Preview template and payload editor to templates form * Add TemplatePreview test and update css * Preview errors for each template that is wrong * Enable preview templating only for Grafana Alert Manager * Use harcoded default payload instead of requesting it to the backend * Update error response in the api definition * Add spinner when loading result for preview * Update api request followind DD changes * Use pre instead of TextArea to render the preview * Fix tests * Add alert list editor * Add start and end time for alert generator * Add preview for data list added in the modal * Update copies and move submit button in alert generator to the bottom * Copy updates * Refactor * Use tab instead of button to preview * Move payload editor next to the content * Copy update * Refactor * Adress PR review comments * Fix wrong json format throwing an exception when adding more data * Use monaco editor for payload * Only show text 'Preview for...' when we have more than one define * Fix some errors * Update CollapseSection style * Add tooltip for the Payload info icon explaining the available list of alert data fields in preview * Set payload as invalid if it's not an array * Fix test * Update text in AlertTemplateDataTable * Add separators to distinguish lines that belong to the preview * Use harcoded default payload instead of requesting it to the backend * Add alert instance picker * Add rule search capability and cleanup * Display alert instance extra information on hover * Rebase and integrate with existing view * Display folder under rule name * Display unique labels for alert instances * Remove unneeded interface * Reset state after closing the modal * Refactor useEffect and useMemo * Move common code to variable * Refactor to avoid setting filtered rules as state * Disable instance selector button when there are errors in the payload * Validate payload on button click * Change warning text * Add support for state filters in alertmanager alerts request * Use RTK Query to fetch alert instances * Address review comments * Fix lint --------- Co-authored-by: Sonia Aguilar <soniaaguilarpeiron@gmail.com>
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Labels
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
What is this feature?
Adds an instance picker to allow users to select active alerts to add to their template payload.
Why do we need this feature?
To provide ease of use when creating new templates.
Who is this feature for?
All users