public void maybeAdd(Object candidate) {
        if (candidate instanceof ClusterResourceListener) {
            clusterResourceListeners.add((ClusterResourceListener) candidate);
        }
    }
Add only if the candidate implements {@link ClusterResourceListener}.
@param candidate Object which might implement {@link ClusterResourceListener}
clients/src/main/java/org/apache/kafka/common/internals/ClusterResourceListeners.java