Question about Multi-threaded Link Checker task #174
-
Hi. I have a difficulty understanding the following subtask:
Is the suggestion here to create a channel on the main thread, which will spawn a new thread whenever it receives a URL and then run a recursive link checker for this URL on the spawned thread? So for instance, a user could simultaneously run two parallel link checkers for site A and site B. Or is it more about parallelizing the recursive checks of the same site? So for instance, you start with the start page of site A, extract a list of URLs from that page and send them to some queue from which several other threads can pick up URLs, process them and add new extracted URLs to the queue, and so on. |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment 2 replies
-
That was my idea: let the checker use, say, 10 threads and let these 10 threads work through the URLs to be checked in parallel. You're exactly right that you'll want to build a queue for this 🙂 |
Beta Was this translation helpful? Give feedback.
That was my idea: let the checker use, say, 10 threads and let these 10 threads work through the URLs to be checked in parallel. You're exactly right that you'll want to build a queue for this 🙂