Fixes #29255: Remove unused LMAX Disruptor event bus and dependency#29256
Merged
Conversation
EventPubSub (LMAX Disruptor) was started and had two handlers attached (AuditLogEventPublisher, EventMonitorPublisher), but its only producer — EventPubSub.publish(ChangeEvent) — has zero callers since the change-event flow moved to the database-backed change_event consumer pattern in #14422. audit_log is written by AuditLogConsumer (Quartz, polls change_event), so the disruptor handlers never fired. Delete the dead disruptor machinery and its orphaned EventMonitor backends, strip the wiring from OpenMetadataApplication, and drop the com.lmax:disruptor dependency. EventMonitorConfiguration/EventMonitorProvider are retained (used by the Micrometer HTTP metrics filter and ServicesStatusJobHandler). Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Contributor
✅ PR checks passedThe linked issue has a description and all required Shipping project fields set. Thanks! |
Code Review ✅ ApprovedRemoves the unused LMAX Disruptor event bus and its associated dependency, effectively cleaning up orphaned code paths. No issues found. OptionsDisplay: compact → Showing less information. Comment with these commands to change:
Was this helpful? React with 👍 / 👎 | Gitar |
|
Contributor
🟡 Playwright Results — all passed (8 flaky)✅ 4312 passed · ❌ 0 failed · 🟡 8 flaky · ⏭️ 88 skipped
🟡 8 flaky test(s) (passed on retry)
How to debug locally# Download playwright-test-results-<shard> artifact and unzip
npx playwright show-trace path/to/trace.zip # view trace |
manerow
approved these changes
Jun 22, 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.



Describe your changes:
Fixes #29255
I removed the LMAX Disruptor event bus (
EventPubSub) and thecom.lmax:disruptordependency because it is dead code. Its only producer,EventPubSub.publish(ChangeEvent), has had zero callers since the change-event flow moved to the database-backedchange_eventconsumer pattern in #14422 —audit_logis now written byAuditLogConsumer(a Quartz job pollingchange_event), so the disruptor's attached handlers (AuditLogEventPublisher,EventMonitorPublisher) never fired. This deletes the orphaned plumbing plus its now-unreferencedEventMonitorbackends and strips the boot wiring fromOpenMetadataApplication.Type of change:
High-level design:
ChangeEventHandler→change_eventtable →AuditLogConsumer(Quartz) →AuditLogRepository.write()→audit_log— is untouched.EventPubSub,EventPublisher,AbstractEventPublisher,AuditLogEventPublisher,EventMonitorPublisher, and the orphanedEventMonitor/EventMonitorFactory/PrometheusEventMonitor/CloudwatchEventMonitor.EventMonitorConfiguration/EventMonitorProvider— still used by the Micrometer HTTP metrics filter andServicesStatusJobHandler.change_eventconsumer.Tests:
Unit tests
Removed 3 obsolete tests for the deleted classes (
CloudWatchEventMonitorTest,EventMonitorFactoryTest,EventMonitorPublisherTest). No new logic was added — this is a pure dead-code removal.Backend integration tests
AuditLogResourceITcontinues to cover the livechange_event→audit_logpath.Manual testing performed
mvn -pl openmetadata-service test-compile— passes (main + test sources compile clean).mvn -pl openmetadata-service spotless:apply— no formatting changes.EventPubSub.publishhas no callers and no remaininglmax/disruptorreferences.UI screen recording / screenshots:
Not applicable.
Checklist:
Fixes <issue-number>: <short explanation>Fixes #29255above.Greptile Summary
Removes the LMAX Disruptor-based
EventPubSuband all attached plumbing (EventPublisher,AbstractEventPublisher,AuditLogEventPublisher,EventMonitorPublisher,EventMonitor*backends) that have had zero live callers since the change-event flow moved to the database-backedchange_eventconsumer pattern. The live audit-log path (ChangeEventHandler→change_eventtable →AuditLogConsumerQuartz job →audit_log) is untouched.EventPubSub, the six publisher/monitor classes, and their three unit tests; removescom.lmax:disruptor 3.4.4from bothpom.xmlfiles.EventPubSub.start(),registerEventPublisher(), andEventPubSub.shutdown()fromOpenMetadataApplication; keepsEventMonitorConfigurationandEventMonitorProvider, which are still consumed byServicesStatusJobHandlerand the Micrometer HTTP-metrics filter.Confidence Score: 4/5
Safe to merge — purely removes dead code and its dependency; no live event path is touched.
The deletion is well-scoped and the live ChangeEventHandler → change_event → AuditLogConsumer → audit_log path is untouched. The only loose end is the software.amazon.awssdk:cloudwatch Maven artifact, which is now orphaned in openmetadata-service/pom.xml now that CloudwatchEventMonitor is gone — it adds unnecessary compile-time weight but does not break anything at runtime.
openmetadata-service/pom.xml — the CloudWatch AWS SDK dependency block should be removed alongside the deleted monitor class.
Important Files Changed
Flowchart
%%{init: {'theme': 'neutral'}}%% flowchart TD subgraph removed["❌ Removed (dead code)"] EP["EventPubSub\n(LMAX Disruptor)"] ALEP["AuditLogEventPublisher"] EMP["EventMonitorPublisher"] EM["EventMonitor\n(CloudWatch / Prometheus)"] EP --> ALEP EP --> EMP EMP --> EM end subgraph live["✅ Live path (unchanged)"] CEH["ChangeEventHandler"] CE["change_event table"] ALC["AuditLogConsumer\n(Quartz job)"] AL["audit_log table"] CEH --> CE --> ALC --> AL end style removed fill:#fdd,stroke:#f66 style live fill:#dfd,stroke:#6a6%%{init: {'theme': 'base', 'themeVariables': {"darkMode": true, "background": "#0d1117", "primaryColor": "#21262d", "primaryTextColor": "#e6edf3", "primaryBorderColor": "#8b949e", "lineColor": "#8b949e", "textColor": "#e6edf3", "edgeLabelBackground": "#161b22", "actorBkg": "#21262d", "actorBorder": "#8b949e", "actorTextColor": "#e6edf3", "actorLineColor": "#8b949e", "signalColor": "#8b949e", "signalTextColor": "#e6edf3", "noteBkgColor": "#373320", "noteBorderColor": "#d4a72c", "noteTextColor": "#f0e6c0", "labelBoxBkgColor": "#21262d", "labelBoxBorderColor": "#8b949e", "labelTextColor": "#e6edf3", "loopTextColor": "#e6edf3", "activationBkgColor": "#30363d", "activationBorderColor": "#8b949e"}}}%% flowchart TD subgraph removed["❌ Removed (dead code)"] EP["EventPubSub\n(LMAX Disruptor)"] ALEP["AuditLogEventPublisher"] EMP["EventMonitorPublisher"] EM["EventMonitor\n(CloudWatch / Prometheus)"] EP --> ALEP EP --> EMP EMP --> EM end subgraph live["✅ Live path (unchanged)"] CEH["ChangeEventHandler"] CE["change_event table"] ALC["AuditLogConsumer\n(Quartz job)"] AL["audit_log table"] CEH --> CE --> ALC --> AL end style removed fill:#fdd,stroke:#f66 style live fill:#dfd,stroke:#6a6Comments Outside Diff (1)
openmetadata-service/pom.xml, line 551-557 (link)software.amazon.awssdk:cloudwatchartifact is now orphaned. Its only Java consumer wasCloudwatchEventMonitor, which was deleted in this PR. No remaining source file undersrc/main/javaimports any class fromsoftware.amazon.awssdk.services.cloudwatch.Note: If this suggestion doesn't match your team's coding style, reply to this and let me know. I'll remember it for next time!
Reviews (1): Last reviewed commit: "Fixes #29255: Remove unused LMAX Disrupt..." | Re-trigger Greptile