dajac opened a new pull request, #23724:
URL: https://github.com/apache/kafka/pull/23724
Depends on #23722 and #23723: only the last commit belongs to this PR.
The unit tests of the uniform2 assignor check hand traced cases, but
its properties must hold for any group and any sequence of changes.
This patch adds a fuzzer checking them on random groups and random
sequences of events: members joining and leaving, one at a time or
several, topics gaining partitions, and subscriptions changing. Other
events make the input stale, as the coordinator can hand it to the
assignor: topics deleted, created again or shrunk while members still
hold their partitions, and empty subscriptions.
Changes:
- `Uniform2FuzzScenario` generates the groups and the events.
- `Uniform2AssignorFuzzTest` checks validity, spread and balance,
determinism under shuffled inputs, the fixed point with the same map
instances, the same map for every member whose partitions do not
change, the movement bounds after a single leave or join, and the
moves of tiny groups, at most one above the fewest found by a brute
force oracle.
- It also checks that the four ways of counting of the balance step
give the same shares, through
`AssignmentTestUtils.sharesPerWayOfCounting`.
- The default run takes seconds; environment variables scale it up,
see the class Javadoc.
--
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]