Simplify half-open timer and fix issue where multiple open handlers could be registered.