code: def exponential_backoff(self):
          
          last_service_switch = self._service_starttime
          if not last_service_switch:
              return
          time_since_last_switch = time.time() - last_service_switch
  
          if not self._service_rapidstarts:
              self._service_rapidstarts = 0
          minimum_wait = 0.1 * (2 ** self._service_rapidstarts)
          minimum_wait = min(5, minimum_wait)
  
          if time_since_last_switch > 10:
              self._service_rapidstarts = 0
              return
          self._service_rapidstarts += 1
          self.log.debug("Slowing down service starts (%.1f seconds)", minimum_wait)
          time.sleep(minimum_wait)
docs: A function that keeps waiting longer and longer the more rapidly it is called.
          It can be used to increasingly slow down service starts when they keep failing.