Ensure the program shuts down in a timely manner by calling shutdown-agents.