Giter Site home page Giter Site logo

Incremental Crawling about polipus HOT 3 CLOSED

taganaka avatar taganaka commented on June 11, 2024
Incremental Crawling

from polipus.

Comments (3)

taganaka avatar taganaka commented on June 11, 2024

Not implemented yet.
Working on a set of new features where you can specify an expire time for each page.
Whether the page is expired, it will downloaded again, by overwriting the old stored doc

As for now a working alternative could be to clean redis-bloomfilter data and override the storage.exists? in your storage adapter to return false even though the page already exists:

https://github.com/taganaka/polipus/blob/master/lib/polipus/storage/mongo_store.rb#L32-L37

module Polipus
  module Storage
    class MongoStore < Base
      def exists? page
        false
      end
    end
  end
end

from polipus.

taganaka avatar taganaka commented on June 11, 2024

@neuralnw
You can try this branch:

https://github.com/taganaka/polipus/tree/incremental_crawling

Major changes:

  • An url part of the initial seeder is always re-downloaded, no matter what
  • A new option is now available:
# Page TTL: mark a page as expired after ttl_page seconds
# Default: nill
:ttl_page => 60
  • Mongo store only:
    page.fetched_at is populated by BSON::ObjectId(_id).generation_time only if page.fetched_at is nil (for legacy data)

Going to merge in the next few days

from polipus.

nengine avatar nengine commented on June 11, 2024

Hi Thanks, I tested and it is working great. Regards.

from polipus.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.