Skip to content

[ResponseOps][MaintenanceWindow] Remove category selection step when adding filters to maintenance windows#227888

Merged
js-jankisalvi merged 65 commits intoelastic:mainfrom
js-jankisalvi:remove-category-mw
Aug 11, 2025
Merged

[ResponseOps][MaintenanceWindow] Remove category selection step when adding filters to maintenance windows#227888
js-jankisalvi merged 65 commits intoelastic:mainfrom
js-jankisalvi:remove-category-mw

Conversation

@js-jankisalvi
Copy link
Contributor

@js-jankisalvi js-jankisalvi commented Jul 14, 2025

Summary

Fixes #226808

This PR removes category selection step when adding filters while creating or editing maintenance windows. It leverages new alert fields api to fetch alert fields across all solutions for filtering.

Before image
After image

Checklist

Check the PR satisfies following conditions.

Reviewers should verify this PR satisfies this list as well.

Release Note

Users can now add filters to maintenance windows based on alert fields from all solutions, without needing to select a category first.

@js-jankisalvi js-jankisalvi self-assigned this Jul 15, 2025
Copy link
Member

@umbopepato umbopepato left a comment

Choose a reason for hiding this comment

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

LGTM, thanks for removing this complexity from MWs Janki! 🎉
I left a couple of nit comments

@joana-cps
Copy link

joana-cps commented Aug 7, 2025

Should we also update this banner in the rule creation page?
Screenshot 2025-08-05 at 10 32 36

Any suggestion for the new text @nastasha-solomon @joana-cps ? Maybe just

Maintenance windows are running.
Rule notifications are stopped while maintenance windows are running.

?

Some suggestions:

Maintenance Window in Progress
Rule notifications are currently paused due to an active maintenance window. Notifications will resume automatically once the maintenance period is over.

Ongoing Maintenance Window
Notifications are paused while the maintenance window is active.

Note that we aim to enhance the way we display this type of message to make it more contextual, as it currently doesn't provide exact information about which ones are affected.

@js-jankisalvi
Copy link
Contributor Author

js-jankisalvi commented Aug 7, 2025

Some suggestions:

Maintenance Window in Progress Rule notifications are currently paused due to an active maintenance window. Notifications will resume automatically once the maintenance period is over.

Ongoing Maintenance Window Notifications are paused while the maintenance window is active.

Note that we aim to enhance the way we display this type of message to make it more contextual, as it currently doesn't provide exact information about which ones are affected.

Thanks @joana-cps

Updated to use existing message. Added link to go to maintenance windows page

image
@js-jankisalvi js-jankisalvi requested a review from a team as a code owner August 8, 2025 13:24
Copy link
Contributor

@banderror banderror left a comment

Choose a reason for hiding this comment

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

The change to x-pack/solutions/security/test/security_solution_cypress/cypress/e2e/detection_response/rule_management/maintenance_windows/maintenance_window_callout.cy.ts LGTM

@js-jankisalvi js-jankisalvi enabled auto-merge (squash) August 11, 2025 14:46
@js-jankisalvi js-jankisalvi merged commit bb6c590 into elastic:main Aug 11, 2025
12 checks passed
@js-jankisalvi js-jankisalvi deleted the remove-category-mw branch August 11, 2025 14:59
@elasticmachine
Copy link
Contributor

💛 Build succeeded, but was flaky

Failed CI Steps

Test Failures

  • [job] [logs] FTR Configs #77 / alerting api integration security and spaces enabled - Group 2 Connectors ServiceNow ITSM ServiceNow ITSM - Executor Execution getChoices should get choices

Metrics [docs]

Module Count

Fewer modules leads to a faster build time

id before after diff
alerting 317 315 -2
apm 1953 1952 -1
cases 1132 1131 -1
datasetQuality 818 817 -1
discover 1383 1382 -1
embeddableAlertsTable 513 512 -1
infra 1527 1526 -1
ml 2499 2498 -1
monitoring 726 725 -1
observability 1392 1394 +2
securitySolution 7864 7866 +2
slo 1233 1232 -1
synthetics 1339 1338 -1
transform 785 784 -1
triggersActionsUi 965 964 -1
uptime 869 868 -1
total -11

Public APIs missing comments

Total count of every public API that lacks a comment. Target amount is 0. Run node scripts/build_api_docs --plugin [yourplugin] --stats comments for more detailed information.

id before after diff
@kbn/alerting-types 275 277 +2
@kbn/alerts-ui-shared 297 302 +5
total +7

Async chunks

Total size of all lazy-loaded chunks that will be downloaded as the user navigates the app

id before after diff
alerting 91.6KB 88.0KB -3.6KB
apm 2.6MB 2.6MB -158.0B
cases 1.3MB 1.3MB -1.1KB
datasetQuality 421.3KB 420.9KB -357.0B
discover 1.1MB 1.1MB -337.0B
embeddableAlertsTable 941.2KB 940.3KB -935.0B
infra 1.0MB 1.0MB -158.0B
ml 5.3MB 5.3MB -335.0B
monitoring 631.1KB 631.0KB -158.0B
observability 1.3MB 1.3MB -100.0B
securitySolution 10.4MB 10.4MB -876.0B
slo 968.6KB 968.4KB -158.0B
synthetics 1.0MB 1.0MB -156.0B
transform 622.5KB 622.2KB -357.0B
triggersActionsUi 1.5MB 1.5MB +34.0B
uptime 491.6KB 491.5KB -158.0B
total -8.8KB

Public APIs missing exports

Total count of every type that is part of your API that should be exported but is not. This will cause broken links in the API documentation system. Target amount is 0. Run node scripts/build_api_docs --plugin [yourplugin] --stats exports for more detailed information.

id before after diff
@kbn/alerts-ui-shared 7 8 +1

Page load bundle

Size of the bundles that are downloaded on every page load. Target size is below 100kb

id before after diff
triggersActionsUi 105.6KB 104.6KB -1000.0B
Unknown metric groups

API count

id before after diff
@kbn/alerting-types 279 281 +2
@kbn/alerts-ui-shared 314 320 +6
total +8

History

cc @js-jankisalvi

adcoelho added a commit that referenced this pull request Aug 12, 2025
…age (#230971)

Closes #230768

## Summary

I removed the banner as discussed offline and we now only display the
`Archive` button.

<img width="1374" height="126" alt="Screenshot 2025-08-07 at 13 39 36"
src="https://github.com/user-attachments/assets/6527fd55-5a4f-4015-bb82-899845ae9b0e"
/>

The modal text was reworded (@nastasha-solomon could you please
proofread the copy?).

<img width="1005" height="409" alt="Screenshot 2025-08-07 at 13 29 41"
src="https://github.com/user-attachments/assets/989e9b19-9f96-4c2f-8757-d13fa45f744b"
/>

<details><summary>Something else I noticed was that we have an ugly
margin in the edit page, right below the `Filters`
section.</summary><img width="1416" height="370" alt="Screenshot
2025-08-07 at 13 24 04"
src="https://github.com/user-attachments/assets/31b7e7c1-d1a4-436e-a121-f56d64ec7598"
/></details>
I was going to remove it, but looking at the code, [this
PR](#227888) should fix it, so I
didn't touch it.
@banderror banderror removed the request for review from nikitaindik August 12, 2025 14:08
NicholasPeretti pushed a commit to NicholasPeretti/kibana that referenced this pull request Aug 18, 2025
…adding filters to maintenance windows (elastic#227888)

## Summary

Fixes elastic#226808

This PR removes category selection step when adding filters while
creating or editing maintenance windows. It leverages [new alert fields
api ](elastic#222032) to fetch alert
fields across all solutions for filtering.

<details><summary>Before</summary>

<img width="1386" height="890" alt="image"
src="https://github.com/user-attachments/assets/c051365c-eb94-492f-a58b-1e7067f39810"
/>

</details> 

<details><summary>After</summary>

<img width="720" height="436" alt="image"
src="https://github.com/user-attachments/assets/267b77c3-a7b9-4785-8313-51532787487d"
/>
</details> 


### Checklist

Check the PR satisfies following conditions. 

Reviewers should verify this PR satisfies this list as well.

- [x] Any text added follows [EUI's writing
guidelines](https://elastic.github.io/eui/#/guidelines/writing), uses
sentence case text and includes [i18n
support](https://github.com/elastic/kibana/blob/main/src/platform/packages/shared/kbn-i18n/README.md)
- [x] [Unit or functional
tests](https://www.elastic.co/guide/en/kibana/master/development-tests.html)
were updated or added to match the most common scenarios

### Release Note
Users can now add filters to maintenance windows based on alert fields
from all solutions, without needing to select a category first.

---------

Co-authored-by: kibanamachine <42973632+kibanamachine@users.noreply.github.com>
NicholasPeretti pushed a commit to NicholasPeretti/kibana that referenced this pull request Aug 18, 2025
…age (elastic#230971)

Closes elastic#230768

## Summary

I removed the banner as discussed offline and we now only display the
`Archive` button.

<img width="1374" height="126" alt="Screenshot 2025-08-07 at 13 39 36"
src="https://github.com/user-attachments/assets/6527fd55-5a4f-4015-bb82-899845ae9b0e"
/>

The modal text was reworded (@nastasha-solomon could you please
proofread the copy?).

<img width="1005" height="409" alt="Screenshot 2025-08-07 at 13 29 41"
src="https://github.com/user-attachments/assets/989e9b19-9f96-4c2f-8757-d13fa45f744b"
/>

<details><summary>Something else I noticed was that we have an ugly
margin in the edit page, right below the `Filters`
section.</summary><img width="1416" height="370" alt="Screenshot
2025-08-07 at 13 24 04"
src="https://github.com/user-attachments/assets/31b7e7c1-d1a4-436e-a121-f56d64ec7598"
/></details>
I was going to remove it, but looking at the code, [this
PR](elastic#227888) should fix it, so I
didn't touch it.
qn895 pushed a commit to qn895/kibana that referenced this pull request Aug 26, 2025
…adding filters to maintenance windows (elastic#227888)

## Summary

Fixes elastic#226808

This PR removes category selection step when adding filters while
creating or editing maintenance windows. It leverages [new alert fields
api ](elastic#222032) to fetch alert
fields across all solutions for filtering.

<details><summary>Before</summary>

<img width="1386" height="890" alt="image"
src="https://github.com/user-attachments/assets/c051365c-eb94-492f-a58b-1e7067f39810"
/>

</details> 

<details><summary>After</summary>

<img width="720" height="436" alt="image"
src="https://github.com/user-attachments/assets/267b77c3-a7b9-4785-8313-51532787487d"
/>
</details> 


### Checklist

Check the PR satisfies following conditions. 

Reviewers should verify this PR satisfies this list as well.

- [x] Any text added follows [EUI's writing
guidelines](https://elastic.github.io/eui/#/guidelines/writing), uses
sentence case text and includes [i18n
support](https://github.com/elastic/kibana/blob/main/src/platform/packages/shared/kbn-i18n/README.md)
- [x] [Unit or functional
tests](https://www.elastic.co/guide/en/kibana/master/development-tests.html)
were updated or added to match the most common scenarios

### Release Note
Users can now add filters to maintenance windows based on alert fields
from all solutions, without needing to select a category first.

---------

Co-authored-by: kibanamachine <42973632+kibanamachine@users.noreply.github.com>
qn895 pushed a commit to qn895/kibana that referenced this pull request Aug 26, 2025
…age (elastic#230971)

Closes elastic#230768

## Summary

I removed the banner as discussed offline and we now only display the
`Archive` button.

<img width="1374" height="126" alt="Screenshot 2025-08-07 at 13 39 36"
src="https://github.com/user-attachments/assets/6527fd55-5a4f-4015-bb82-899845ae9b0e"
/>

The modal text was reworded (@nastasha-solomon could you please
proofread the copy?).

<img width="1005" height="409" alt="Screenshot 2025-08-07 at 13 29 41"
src="https://github.com/user-attachments/assets/989e9b19-9f96-4c2f-8757-d13fa45f744b"
/>

<details><summary>Something else I noticed was that we have an ugly
margin in the edit page, right below the `Filters`
section.</summary><img width="1416" height="370" alt="Screenshot
2025-08-07 at 13 24 04"
src="https://github.com/user-attachments/assets/31b7e7c1-d1a4-436e-a121-f56d64ec7598"
/></details>
I was going to remove it, but looking at the code, [this
PR](elastic#227888) should fix it, so I
didn't touch it.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

backport:skip This PR does not require backporting Feature:Maintenance Window release_note:enhancement Team:ResponseOps Platform ResponseOps team (formerly the Cases and Alerting teams) t// v9.2.0

7 participants