mirror of
https://github.com/floci-io/floci.git
synced 2026-11-24 06:20:24 -05:00
DocDbQueryHandler, NeptuneQueryHandler, and RdsQueryHandler each carried their own byte-for-byte identical handleDescribeGlobalClusters: global clusters aren't modeled by any of the three, so all three validate MaxRecords/GlobalClusterIdentifier/Marker the same way and always answer with an empty GlobalClusters list, since DocumentDB and Neptune both accept the RDS-family wire protocol and claim compatibility for this operation. Extracted into a new RdsFamilyQuerySupport under core.common (a static utility, not a CDI-injected sibling handler like RdsQueryHandler's existing DocDbQueryHandler/ NeptuneQueryHandler dependencies: those exist for real cross-service data composition, this operation has no state to share, just identical logic). Each handler's own handleDescribeGlobalClusters is now a one-line delegation, keeping its own LOG so log lines still attribute to the right service. Scope note: CPD also flagged the two other pairwise overlaps this issue names (33-line DocDb/RDS, 26-line Neptune/RDS), but those turned out to be the same handleDescribeGlobalClusters match window overlapping into neighboring methods, not a separate duplicate; this extraction covers them too. A much larger set of CPD matches between DocDbQueryHandler and NeptuneQueryHandler (cluster/instance CRUD, tag parsing, XML builders, effectively most of both handlers) is a separate, pre-existing architectural duplication between those two services well beyond what this issue asks for, and is not touched here. No behavior change. Full docdb, neptune, and rds test suites pass unchanged (one NeptuneOpenCypherIntegrationTest Bolt-protocol timeout is a pre-existing environmental flake, confirmed by reproducing it identically against unmodified main).