You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
finding: two consumer-local structural DataEngineLike re-declarations remain after the #11493 deletion (datasource-admin-plugin, service-analytics) #11833
Found while carrying out #11493 (which deleted service-datasource/src/plugin.ts's structural DataEngineLike per the maintainer ruling there). Filed unassigned as an observation, measured at eab6d131b.
The observation
Two more consumer-local structural engine types survive in-tree, same pattern the #4251 B3 sweep replaced with declared contract members ("seven consumer-local surface declarations"):
packages/services/service-datasource/src/datasource-admin-plugin.ts (~line 44) — DataEngineLike declaring registerDriver? / registerDatasourceDef? / getDriverByName? plus all-optional sys_metadata CRUD (findOne/find/insert/update/delete) used for hot pool (de)registration and durable datasource-record persistence.
The #11493 four-facet reasoning applies one seam over: a private structural type meets no compiler on the producer side, so engine-surface drift lands silently in the consumer. But both sites are deliberate graceful-degradation seams (absent members degrade to in-memory / reduced capability), and moving them to Partial<IObjectQLEngine>-style derived types or new optional contract members is a design decision with its own blast radius — needs its own pass, not a rider.
Refs: #11493 (the ruling + the deleted third instance) · #4251 (B3 — the declared-contract sweep this pattern predates/escaped).
Found while carrying out #11493 (which deleted
service-datasource/src/plugin.ts's structuralDataEngineLikeper the maintainer ruling there). Filed unassigned as an observation, measured ateab6d131b.The observation
Two more consumer-local structural engine types survive in-tree, same pattern the #4251 B3 sweep replaced with declared contract members ("seven consumer-local surface declarations"):
packages/services/service-datasource/src/datasource-admin-plugin.ts(~line 44) —DataEngineLikedeclaringregisterDriver?/registerDatasourceDef?/getDriverByName?plus all-optional sys_metadata CRUD (findOne/find/insert/update/delete) used for hot pool (de)registration and durable datasource-record persistence.packages/services/service-analytics/src/plugin.ts(~line 19) —DataEngineLikedeclaringaggregate(with the engine.aggregate: add per-aggregation filter to the contract — ruled half of #10413 (measure-level filters on the ObjectQL analytics path) #10576 per-aggregationfilter) andexecutefor the analytics bridge.What was verified (and what was not)
registerDatasourceDefexists onObjectQL(packages/objectql/src/engine.ts,registerDatasourceDef(def: …): void),registerDriver/getDriverByNameare on the contract/engine, and the CRUD members exist onIDataEngine. Unlike thegetDatasourceDriver?member The engine-registration path is still unreached by the introspection compile channel:IDataDriverdeclares nointrospectSchema, andIDataEngine.introspectDatasource()returnsPromise<unknown>#11493 deleted (zero references outside its file, a probe no engine ever matched), no dead member was found here — this is a pattern observation, not a measured defect.IDataEngine/IObjectQLEnginemembers they shadow — that is exactly the drift the The service-lookupanyrule missesgetService<any>(...)— 80 sites erase the slot contract, 3 of them inside the rule's own scope #4251 contract exists to prevent, and nothing compiles these local declarations against the real engine.Why it may deserve a card (and why not now)
The #11493 four-facet reasoning applies one seam over: a private structural type meets no compiler on the producer side, so engine-surface drift lands silently in the consumer. But both sites are deliberate graceful-degradation seams (absent members degrade to in-memory / reduced capability), and moving them to
Partial<IObjectQLEngine>-style derived types or new optional contract members is a design decision with its own blast radius — needs its own pass, not a rider.Refs: #11493 (the ruling + the deleted third instance) · #4251 (B3 — the declared-contract sweep this pattern predates/escaped).