I would use Threads::Queue to send messages back from your threads to your main thread instead of polling them for becoming ->joinable.
For passing thread results back otherwise, see threads, which documents the return value of ->join(). I would avoid using that, because to get more speed, you will want to keep a pool of worker threads and pass the queries to them using another Thread::Queue instead, thus saving the cost of creating and destroying a new thread for every request.
In reply to Re^4: Should I use threads? Perl/DHCP/Radius
by Corion
in thread Should I use threads? Perl/DHCP/Radius
by Anonymous Monk
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |