in reply to Perl Threads
I don't believe threads can be killed (sanely), so I'd recommend using child processes instead of threads.
Scenario 1: The child processes interface with the database directly and don't tell the parent when they're done.
Solution: You could use wait with a calculated timeout imposed by alarm.
Scenario 2: The child processes let the parent know when they're done, possibly sending the data to the parent instead of interfacing with the database.
Solution: You could use select with a calculated timeout.
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re^2: Perl Threads
by jpk236 (Monk) on Nov 06, 2007 at 22:26 UTC | |
by ikegami (Patriarch) on Nov 06, 2007 at 22:40 UTC |