This spawns a new thread every time this section of code is executed. I can't imagine it performing well, though perhaps this is the best way given Ruby's resolver doesn't appear to support timeouts in any reasonable way :(