private void setAndPropagateAssignment(ClassicGroup group, Map<String, byte[]> assignment) {
        if (!group.isInState(COMPLETING_REBALANCE)) {
            throw new IllegalStateException("The group must be in CompletingRebalance state " +
                "to set and propagate assignment.");
        }

        group.allMembers().forEach(member ->
            member.setAssignment(assignment.getOrDefault(member.memberId(), EMPTY_ASSIGNMENT)));

        propagateAssignment(group, Errors.NONE);
    }
Sets assignment for group and propagate assignment and error to all members.

@param group      The group.
@param assignment The assignment for all members.
group-coordinator/src/main/java/org/apache/kafka/coordinator/group/GroupMetadataManager.java