code: def check_h2o_clustered(pod_ips):
      """
      Checks each and every H2O pod identified by its Kubernetes ClusterIP reports a healthy cluster of given size.
      If any node is unresponsive or reports wrong cluster status, this script is exited with status code 1.
      :param pod_ips:  A list of pod IPs (IPv4), each IP in a separate string.
      """
      for pod_ip in pod_ips:
          url = "http://{}:8080/cluster/status".format(pod_ip)
  
          response = None
          max_retries = 360
          retries = 0
          while retries < max_retries:
              response = requests.get(url)
              if response.status_code == 200:
                  break
              time.sleep(1)
  
          if response is None:
              print(
                  "Unable to obtain /cluster/status response from pod '{}' in time.".format(
                      pod_ip
                  )
              )
              sys.exit(1)
  
          response_json = response.json()
          if len(response_json["unhealthy_nodes"]) > 0:
              print(
                  "Unhealthy nodes detected in the cluster: {}".format(
                      response_json["unhealthy_nodes"]
                  )
              )
              sys.exit(1)
  
          if len(response_json["healthy_nodes"]) != len(pod_ips):
              print(
                  "Healthy cluster with less node reported by node {}. IPs: {}".format(
                      pod_ip, response_json["healthy_nodes"]
                  )
              )
              sys.exit(1)
  
          print(
              "Pod {} reporting healthy cluster:\n{}".format(
                  pod_ip, response_json
              )
          )
  
file_path: h2o-3/h2o-k8s/tests/clustering/assisted-clustering.py
imports: import requests
  import argparse
  import sys
  import os
  import time
  from kubernetes import client, config, watch
label_desc: Use image node_id 6 for calling a global function with example usage: check_h2o_clustered(pod_ips) without return types