Ejemplo n.º 1
0
 def _check_timeout(self, start_time=None):
     if self.POD_RUN_WAIT_TIMEOUT_SECONDS == -1:
         return
     elapsed_time = time.time() - start_time
     if elapsed_time >= self.POD_RUN_WAIT_TIMEOUT_SECONDS:  # timeout
         raise TimedOutException(
             "Timed out running one-off CronJob: [ {} ]".format(self.name))
Ejemplo n.º 2
0
 def _check_timeout(self, start_time=None):
     elapsed_time = time.time() - start_time
     if elapsed_time >= self.SCALE_WAIT_TIMEOUT_SECONDS:  # timeout
         raise TimedOutException(
             "Timed out scaling Deployment: [ {} ] to replica count: [ {} ]".format(
                 self.name,
                 self.desired_replicas))
Ejemplo n.º 3
0
 def _wait_for_readiness(self):
     start_time = time.time()
     while not self.is_ready():
         time.sleep(0.2)
         elapsed_time = time.time() - start_time
         if elapsed_time >= self.POD_READY_TIMEOUT_SECONDS:
             raise TimedOutException(
                 "Timed out on Pod readiness: [ {0} ]".format(self.name))
Ejemplo n.º 4
0
 def _check_timeout(self, start_time=None):
     elapsed_time = time.time() - start_time
     if elapsed_time >= READY_WAIT_TIMEOUT_SECONDS:  # timeout
         raise TimedOutException(
             "Timed out waiting on readiness of PersistentVolume: [ {} ]".
             format(self.name))
Ejemplo n.º 5
0
 def _check_timeout(self, start_time=None):
     elapsed_time = time.time() - start_time
     if elapsed_time >= self.DRAIN_WAIT_TIMEOUT_SECONDS:  # timeout
         raise TimedOutException("Timed out draining K8sNode: [ {0} ]".format(self.name))
Ejemplo n.º 6
0
 def _check_timeout(self, start_time=None, p=None):
     elapsed_time = time.time() - start_time
     if elapsed_time >= self.SCALE_WAIT_TIMEOUT_SECONDS:  # timeout
         raise TimedOutException(
             "Timed out scaling job: [ {0} ] to parallelism: [ {1} ]".
             format(self.name, p))