fix(cdc): fail closed on duplicate connector registry IDs - #201
fix(cdc): fail closed on duplicate connector registry IDs#201seonghobae wants to merge 4 commits into
Conversation
|
Important Review skippedDraft detected. Please check the settings in the CodeRabbit UI or the ⚙️ Run configurationConfiguration used: Organization UI Review profile: CHILL Plan: Pro Plus Run ID: You can disable this status message by setting the Use the checkbox below for a quick retry:
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
|
Superseded by current-base replacement #306; unique behavior and regression coverage are preserved without rewriting this stale branch. Fresh preservation proof:
Closing #201 as a stale-base duplicate. Checks/reviews from #201 do not transfer to #306; #306 must satisfy its own exact-head gates. |
Purpose
Fix #200 test-first from protected
develop@622e5e6c3d534f230c390f10e3832efadfc01825. CDC connector IDs are execution/discovery authority selectors, but both source and target registries historically used unconditionalMap.put, so a later connector with the same ID silently replaced the earlier registration.This direct-
developDraft changes only CDC source/target registry identity validation plus focused tests. It does not alter MySQL/SQL Server discovery retirement (#158/#163), target-SPI capability architecture (#202), connector credentials, or provider support claims.Exact current identity
develop@622e5e6c3d534f230c390f10e3832efadfc01825;fix/cdc-duplicate-connector-ids-622e5e6;f2683286c4a768ead11da0895a511ab2bec9af88;28b01de58d0c24cec864ef63bd9b9f3697c936d1;1ba5527effcc4605b44d53effd0dfb3be3618164;45769b73c0b910eab09264e92ea87cf0291062e8;Every check/review from a predecessor source head is historical and does not transfer.
RCA / RED
Registry
register(...)methods usedbyId.put(id, connector), making identity uniqueness an accidental map behavior rather than a validated authority invariant. REDf268328...addedCdcRegistryIdentityTestfirst. CI31349125275on synthetic merge2cc52ed...ran the real registry code and all four new duplicate/blank-ID assertions failed because no exception was thrown.GREEN + defensive-branch coverage
28b01de58d0c24cec864ef63bd9b9f3697c936d1makes both registries fail closed on null/blank/duplicate IDs using bounded validation andputIfAbsent, preserves deterministic unique registration order, keeps the empty source-registry PostgreSQL fallback, and documents the public identity contract.A later test-only commit
1ba5527effcc4605b44d53effd0dfb3be3618164adds explicit null-source/null-target regression coverage for the newly introduced defensive branches. No production semantics changed after the implementation GREEN.Current-head CI
31350073782completed successfully on the hosted matrix. Dependency Review31350073785, CycloneDX SBOM31350073797, and SAST Semgrep31350073795also succeeded.Current Security Scan RCA
Security Scan
31350073774is failed, not merely incomplete. Hard Trivy job93339083060checked out synthetic merge45769b73c0b910eab09264e92ea87cf0291062e8and reported the six inherited protected-base Jackson findings forjackson-databind:CVE-2026-54515,CVE-2026-59889, andGHSA-mhm7-754m-9p8wat both root andetl-servicedependency views. Shared remediation #160 remains the correction owner; duplicating that BOM change or suppressing the findings in this registry PR is rejected.The same Trivy run also printed
Dependency version cannot be determined. Child dependencies will not be found.. Issue #196 independently records that even a zero-findings result with this warning would be incomplete security evidence. Here the scan is already hard-failed on real inherited findings.The current protected source-executing workflows remain synthetic-merge based, and inherited JaCoCo can still analyze zero ETL production classes (#162/#164). Source identity, vulnerability findings/completeness, and coverage non-vacuity are separate gates.
Review / scope
Formal reviews are absent and unresolved review threads were zero at the latest refresh. This PR validates registry identity only; #202 separately owns the mismatch between live CDC target product paths and unwired canonical target
write(...)adapters.Merge boundary
Keep Draft. Do not merge until the shared Jackson baseline is accepted/integrated and this unchanged behavior is freshly revalidated against the resulting live base; the exact source then needs accepted literal-source CI/security evidence, complete same-revision dependency/vulnerability evidence, non-vacuous owned-production coverage, every required dependency/SBOM/SAST/security gate, zero valid unresolved findings, and qualifying independent non-author approval where governance requires it. No predecessor-head, other-PR, incomplete-scanner, status-only or synthetic-merge-only evidence transfers.