Added ShutdownHook to gracefully shut down ExecutionManager.