big tidy in response to code review for HttpLatencyDetector and misc improvements