search

Home  >  Q&A  >  body text

pyspider +mongodb 多个爬虫 result 如何指定 collection 名称

如题,我现在需要爬取多个网站的内容,但是结果结构是一样的。现在的配置resultdb 是一个db,每个爬虫的结果分别是不同的集合。而我想把这些结果保存到指定db下的指定集合,这个如何设置。请大侠帮我解答下。

过去多啦不再A梦过去多啦不再A梦2843 days ago995

reply all(1)I'll reply

  • 怪我咯

    怪我咯2017-04-28 09:07:44

    The built-in resultdb is only used to display preview results. If you change the structure, this function will be invalid. So after you get the results, you need to build your own database and handle how to store them.

    http://docs.pyspider.org/en/latest/Working-with-Results/

    reply
    0
  • Cancelreply