code: def check(self):
          
          try:
              self.join(timeout=0)
          except Exception as e:
              logger.exception(e)
              raise
docs: Attempt to join any existing scaler threads that may have died or finished. This insures
          any exceptions raised in the threads are propagated in a timely fashion.