Skip to content

[8.19] [Security Solution] Fix race condition when Defend is installed before rules package (#222200)#224193

Merged
kibanamachine merged 1 commit intoelastic:8.19from
kibanamachine:backport/8.19/pr-222200
Jun 17, 2025
Merged

[8.19] [Security Solution] Fix race condition when Defend is installed before rules package (#222200)#224193
kibanamachine merged 1 commit intoelastic:8.19from
kibanamachine:backport/8.19/pr-222200

Conversation

@kibanamachine
Copy link
Contributor

Backport

This will backport the following commits from main to 8.19:

Questions ?

Please refer to the Backport tool documentation

…e rules package (elastic#222200)

## Summary

Fixes a race condition where the Elastic Defend rule is installed before
the rules package becomes available, resulting in the following error:

```
[2025-05-29T10:40:00.066-04:00][ERROR][plugins.securitySolution.endpointFleetExtension] Unable to find Elastic Defend rule in the prebuilt rule assets (rule_id: 9a1a2dae-0b5f-4c3d-8305-a268d404c306)
```

### Steps to Reproduce

1. Start with a clean Kibana instance with no rules package installed.
2. Navigate directly to the Integrations page (without visiting any
Security Solution pages, which would trigger rules package
bootstrapping), and install the Elastic Defend integration.
3. Observe the `Unable to find Elastic Defend rule in the prebuilt rule
assets` error in the Kibana logs.

This race condition appears to have existed for some time but was
surfaced more clearly due to the recently added warning when the Defend
rule cannot be installed.

(cherry picked from commit c513625)
@kibanamachine kibanamachine merged commit 07b9e73 into elastic:8.19 Jun 17, 2025
11 checks passed
@elasticmachine
Copy link
Contributor

💚 Build Succeeded

Metrics [docs]

✅ unchanged

cc @xcrzx

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

backport This PR is a backport of another PR

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants