class KubeUtil {

    public static boolean isFarzoneNode(List<String> farzones, V1Node node) {
        Map<String, String> labels = node.getMetadata().getLabels();
        if (CollectionsExt.isNullOrEmpty(labels)) {
            return false;
        }
        String nodeZone = labels.get(KubeConstants.NODE_LABEL_ZONE);
        if (StringExt.isEmpty(nodeZone)) {
            logger.debug("Node without zone label: {}", node.getMetadata().getName());
            return false;
        }
        for (String farzone : farzones) {
            if (farzone.equalsIgnoreCase(nodeZone)) {
                logger.debug("Farzone node: nodeId={}, zoneId={}", node.getMetadata().getName(), nodeZone);
                return true;
            }
        }
        logger.debug("Non-farzone node: nodeId={}, zoneId={}", node.getMetadata().getName(), nodeZone);
        return false;
    }

}