Added support for timeouts in monitors