Gracefully shutdown workers