Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

simplecrawler-mongo-queue

Package Overview
Dependencies
Maintainers
1
Versions
7
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

simplecrawler-mongo-queue

MongoDB queue implementation for simplecrawler

  • 1.0.1
  • latest
  • Source
  • npm
  • Socket score

Version published
Maintainers
1
Created
Source

MongoDB queue for Simplecrawler

npm Travis (.org) Dependency Status devDependency Status Greenkeeper badge

This is a queue implementation for simplecrawler powered by MongoDB.

Installation

npm install --save simplecrawler-mongo-queue

Usage

First of all, create a new Simplecrawler instance as described in the documentation. Then create the queue instance and assign it to crawler.queue property.

const Crawler = require('simplecrawler');
const MongoQueue = require('simplecrawler-mongo-queue');

(async () => {
  const crawler = new Crawler('http://example.com');
  crawler.queue = await MongoQueue.create(datastore, name);
  crawler.start();
})();

The create method returns MongoQueue instance and has two arguments:

  • datastore - the application should provide a MongoDB collection where the queue will be stored.
  • name (optional) - a name of the queue to distinguish the different crawlers. If the argument is omitted the constructor creates a random queue name.

Resources

Keywords

FAQs

Package last updated on 26 Oct 2019

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc