-
Notifications
You must be signed in to change notification settings - Fork 8.3k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[Fleet] validate all agent policies before updating them on output de…
…lete (#174921) ## Summary Closes #165817 Moved the logic of validating agent policies before updating any agent policies on output delete. This fixes the scenario where the output delete fails on an agent policy with fleet-server integration, but some agent policies were already updated by then. To verify: - create a logstash output and make it default for data and monitoring output - create a fleet server policy (with fleet server integration) with data and monitoring output set to elasticsearch output - create another agent policy with data and monitoring output set to elasticsearch output - attempt to delete the elasticsearch output, expect a UI error - check that the agent policies are still referencing the elasticsearch output, not the logstash one ### Checklist - [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
- Loading branch information
1 parent
3dc5d2e
commit 36fbfed
Showing
3 changed files
with
141 additions
and
17 deletions.
There are no files selected for viewing
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
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
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