We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
笑虎大神你好: 刚接触爬虫这个领域,看了一下你的源代码,觉得设计的很好,我这里有个小小的疑问,你看我理解的对不对。 我的疑问是fetcher,parser,saver多线程之间是怎样相互协调的。 我的理解是在你的ThreadThreadPool里面有_number_dict这个变量,这个变量是所有其他线程共享的,其实相当于semaphore的想法,每次更新都需要lock起来,比如当fetcher获取到了新的url,parser就可以去根据这个信号量的变化进行下一步的工作。 你看我这样理解对吗? 谢谢
The text was updated successfully, but these errors were encountered:
No branches or pull requests
笑虎大神你好:
刚接触爬虫这个领域,看了一下你的源代码,觉得设计的很好,我这里有个小小的疑问,你看我理解的对不对。
我的疑问是fetcher,parser,saver多线程之间是怎样相互协调的。
我的理解是在你的ThreadThreadPool里面有_number_dict这个变量,这个变量是所有其他线程共享的,其实相当于semaphore的想法,每次更新都需要lock起来,比如当fetcher获取到了新的url,parser就可以去根据这个信号量的变化进行下一步的工作。
你看我这样理解对吗?
谢谢
The text was updated successfully, but these errors were encountered: