This issue is a follow up from the original Alerting changes issue.
The current implementation use /_xpack/usage to determine whether to bootstrap the monitoring alerts in x-pack/plugins/monitoring/server/lib/elasticsearch/verify_alerting_security.ts. But we replaced this logic for alerting framework to use areAPIKeysEnabled check exposed by the security API. Stack monitoring alerts should follow this logic as well. Otherwise we may run into the issue where alerting is enabled but none of the stack monitoring alerts are created.
This issue is a follow up from the original Alerting changes issue. The current implementation use
/_xpack/usage
to determine whether to bootstrap the monitoring alerts inx-pack/plugins/monitoring/server/lib/elasticsearch/verify_alerting_security.ts
. But we replaced this logic for alerting framework to useareAPIKeysEnabled
check exposed by the security API. Stack monitoring alerts should follow this logic as well. Otherwise we may run into the issue where alerting is enabled but none of the stack monitoring alerts are created.