chore: remove unused 3-arg McpUsageRecorder.record overload - #32786
chore: remove unused 3-arg McpUsageRecorder.record overload#32786detail-app[bot] wants to merge 1 commit into
Conversation
|
Hi there 👋 Thanks for your contribution! The OpenMetadata team will review the PR shortly! Once it has been labeled as Let us know if you need any help! |
✅ Playwright Results — workflow succeededValidated commit ✅ 557 passed · ❌ 0 failed · 🟡 0 flaky · ⏭️ 0 skipped · 🧰 0 lifecycle flaky PerformanceBlocking targets: ✅ met · Optimization targets: 🟡 in progress Shard-job maxima below are not the full workflow wall time; the linked run includes build, fixture, planning, and reporting. 🕒 Full workflow signal wall (to summary) 46m 55s ⏱️ Max setup 4m 16s · max shard execution 18m 30s · max shard-job elapsed before upload 21m 29s · reporting 4s 🌐 235.30 requests/attempt · 2.82 app boots/UI scenario · 26.76% common-shard skew Optimization targets still in progress:
How to debug locally# Download playwright-test-results-<shard> artifact and unzip
npx playwright show-trace path/to/trace.zip # view trace |
Describe your changes:
No issue linked — dead code cleanup.
I removed the unused 3-arg
McpUsageRecorder.record(String, String, boolean)overload and its dedicatedlegacy3ArgOverloadOmitsPhase3Fieldstest, because the only production caller (McpServer) uses the 6-arg form.The 3-arg overload was the original signature; the single production call site was migrated to the 6-arg overload in the same commit that introduced the 6-arg form, leaving the 3-arg as a delegating shim whose "kept so existing call sites compile unchanged" comment was stale — no production call sites remained. Its only callers were in
McpUsageRecorderTest.The 5 remaining tests that exercised general recording behavior via the shim now call the 6-arg overload with
null, null, null(exactly what the removed overload delegated to), so behavior under test is unchanged. The 6-argrecordmethod, its privateresolveMcpApp/getDaohelpers, and all logging are left intact (live code with a production caller).Type of change:
High-level design:
N/A — small change.
Tests:
Use cases covered
Unit tests
McpUsageRecorderTestcallers to use the 6-arg overload; removed the now-deadlegacy3ArgOverloadOmitsPhase3Fieldstest.mvn test -pl openmetadata-mcp -Dtest=McpUsageRecorderTestpasses (6 tests, 0 failures).Backend integration tests
Ingestion integration tests
Playwright (UI) tests
UI screen recording / screenshots:
Not applicable.
Checklist:
Fixes <issue-number>: <short explanation>Fixes #<issue-number>above.History
Dead Code PRs can be configured here.