in reply to Parallel Search using Thread::Pool
The simplest architecture is to create a Thread::Queue, then have each of your search modules run in separate threads and enqueue their results as they get them. Your main thread can the read them off the other of of that shared queue and display them.
Thread::Pool will not be useful to you as it is meant to run many copies of the same routine concurrently, but your application calls for running different subroutines in each of your threads.
Depending whether your application is web, gui or console based, you might also want to use a second queue or shared scalar to pass new search terms to your threads.
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re^2: Parallel Search using Thread::Pool
by shanu_040 (Sexton) on Mar 17, 2009 at 11:22 UTC | |
by Anonymous Monk on Mar 17, 2009 at 12:00 UTC | |
by shanu_040 (Sexton) on May 22, 2009 at 18:42 UTC | |
|
Re^2: Parallel Search using Thread::Pool
by shanu_040 (Sexton) on Jun 01, 2009 at 09:34 UTC | |
by BrowserUk (Patriarch) on Jun 01, 2009 at 13:41 UTC | |
by shanu_040 (Sexton) on Jun 02, 2009 at 04:56 UTC | |
by BrowserUk (Patriarch) on Jun 02, 2009 at 10:59 UTC | |
by shanu_040 (Sexton) on Jun 03, 2009 at 04:12 UTC | |
|