refactored listen queue management