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
feat: split BatchPartitioner::try_new into hash and round-robin constructors (#19668)
### Which issue does this PR close?
Closes#19664
---
### Rationale for this change
After #18880, `BatchPartitioner::try_new` gained additional parameters
that are
only relevant for round-robin repartitioning. This made the constructor
API
confusing, as hash repartitioning received parameters it does not use.
Splitting the constructor improves clarity and avoids passing
round-robin–specific parameters to hash partitioning.
---
### What changes are included in this PR?
- Introduce `BatchPartitioner::try_new_hash`
- Introduce `BatchPartitioner::try_new_round_robin`
- Refactor callers to use the specialized constructors
- Retain `BatchPartitioner::try_new` as a delegator for backward
compatibility
This is a pure refactor; behavior is unchanged.
---
### Are these changes tested?
Yes. Existing tests cover this code path.
All builds pass locally.
---
### Are there any user-facing changes?
No. This change is internal only and does not affect user-facing
behavior or APIs.
---------
Co-authored-by: Your Name <[email protected]>
0 commit comments