Remove the always-on alarm-to-event conversion (EventHookCallback)#13925
Merged
Conversation
A triggered alarm is no longer synthesized into the events pipeline as an Alarm/AlarmRecovery event; events now originate only from real event sources (agents, SkyWalking CLI, Kubernetes Event Exporter). Alarms remain available through the alarm store (getAlarm/queryAlarms) and the configured alarm hooks. - Delete EventHookCallback and its unconditional registration in NotifyHandler. - Delete EventHookCallbackTest. - Drop the now-dead event-analyzer dependency from server-alarm-plugin. - Remove the 'Alarm' Known-Event row from event.md; update the e2e guide recipe. - Update the alarm/baseline e2e expected files to assert 'events: []' — the alarm now correlates no synthetic event (swctl 'alarm ls' still projects the events field, so the expectation must assert the empty list). - Add a CHANGES entry.
312d625 to
c29ac55
Compare
wankai123
approved these changes
Jun 23, 2026
This file contains hidden or 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
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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.
Remove the always-on alarm-to-event conversion (
EventHookCallback)EventHookCallbackwas wired unconditionally inNotifyHandler.init()(not part ofAlarmHooksType, no config, no off switch), so every triggered alarm was synthesized into the events pipeline as anAlarm(Type.Error) /AlarmRecovery(Type.Normal) event viaEventAnalyzerService.analyze(...).This conflated two distinct concepts: alarm is alarm, event is only from event. After this change, events originate only from real event sources (agents, SkyWalking CLI, Kubernetes Event Exporter). Alarms remain fully available through the alarm store (
getAlarm/queryAlarms) and the configured alarm hooks (Webhook/gRPC/Slack/WeChat/DingTalk/Feishu/WeLink/PagerDuty/Discord).Notes:
EVENTscope), so this is a clean removal, not a correctness fix.AlarmQuery.findRelevantEvents, theAlarmMessage.eventsGraphQL field) is kept — it surfaces real events on the alarmed entity as root-cause context and is consistent with the principle.event-analyzerdependency fromserver-alarm-pluginto complete the decoupling.Changes:
Delete
EventHookCallbackand its registration inNotifyHandler; deleteEventHookCallbackTest.Drop the
event-analyzerdependency fromserver-alarm-plugin/pom.xml.Remove the
Alarmrow from the "Known Events" table indocs/en/concepts-and-designs/event.md(it was the only event sourced "from internal SkyWalking OAP", contradicting the doc's own framing).Update the alarm/baseline e2e expected files and the e2e guide recipe that asserted the synthetic
Alarmevent.If this pull request closes/resolves/fixes an existing issue, replace the issue number. Closes #.
Update the
CHANGESlog.