in reply to non-blocking listen on a tcp server
Perhaps you should spend some time learning POE or AnyEvent.