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
This commit was created on GitHub.com and signed with GitHub’s verified signature.
What's changed
perf: drop per-twin inheritance fallback in is_of_model (#110) — resolves #101
The legacy traversal ran a nested Cypher query for every candidate twin when the requested model had no precomputed property, making an scan cost O(twins × models) and appear to hang on graphs with no matching twins.
Now resolves inheritance solely from the requested model's precomputed array and returns when it is absent. Pre-fix: 8 952 ms over 2 000 twins (zero matches). Post-fix: 59 ms.
Behaviour change (deliberate): models without a property (graphs written by an older library version, or externally) no longer resolve inheritance — twins match on exact model id only. Re-submitting the affected models' DTDL via restores the property.
Regression test added (2000 twins, 2 s budget + 60 s hang guard); CI green across PG16/17/18 × apache/cnpg.