LuciferYang opened a new pull request, #13227: URL: https://github.com/apache/gravitino/pull/13227
### What changes were proposed in this pull request? `SingleFieldTransform.equals` now compares classes instead of using `instanceof` (matching `BucketTransform` and the other sibling transforms), with a justified `EqualsGetClass` suppression because the base class is abstract. ### Why are the changes needed? With the `instanceof` check, different transform strategies over the same field compared equal (`year(ts).equals(identity(ts))` was `true`), so a `HashSet` silently deduplicated distinct partitioning transforms. Fix: #13226 ### Does this PR introduce _any_ user-facing change? Yes. This changes `equals` semantics for the `@Evolving` transform API: transforms of different strategies over the same field are no longer equal. It fixes silent `HashSet` deduplication of distinct transforms. ### How was this patch tested? Added `TestTransformsEquality`, which pins that transforms of different strategies over the same field are not equal and are not collapsed by a `HashSet`; it fails on the pre-fix tree and passes after the fix. -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: [email protected] For queries about this service, please contact Infrastructure at: [email protected]
