def METHOD_NAME(self, sig_num, stack_frame):
    log.info(f"Shutdown requested via {str(sig_num)}")
    reactor.callLater(0, reactor.stop)
    waited = 0
    while reactor.running:
        if waited > 5:
            log.error("timed out waiting for reactor shutdown")
            break
        time.sleep(0.1)
        waited += 0.1
    if self.mcp:
        self.mcp.shutdown()
    MesosClusterRepository.shutdown()
    KubernetesClusterRepository.shutdown()
    raise SystemExit(f"Terminating on signal {str(sig_num)}")