public boolean addPendingMember(String memberId) {
        if (hasMember(memberId)) {
            throw new IllegalStateException("Attempt to add pending member " + memberId +
                " which is already a stable member of the group.");
        }
        return pendingJoinMembers.add(memberId);
    }
Add a pending member.

@param memberId the member id.
@return true if the group did not already have the pending member,
        false otherwise.
group-coordinator/src/main/java/org/apache/kafka/coordinator/group/classic/ClassicGroup.java