Git Product home page Git Product logo

netdiscovery's Introduction

NetDiscovery

@Tony沈哲 on weibo License Codacy Badge

功能特点:

  • 轻量级爬虫
  • 模块化设计,便于扩展:支持多种消息队列(Disruptor、Redis、Kafka、RabitMQ、RocketMQ)、多种网络框架(Http Client、Okhttp3、Selenium等),也支持自己实现。
  • 支持分布式
  • 多线程、异步化:底层使用 RxJava 2 的多线程机制
  • 支持 Request 添加到正在运行爬虫的 Queue 中
  • 支持 Kotlin 协程
  • 支持 JS 渲染
  • 支持 Request 自定义 header 信息
  • 支持 debug 功能:在调试时 Request 可以打开 debug 的开关,使用 RxCache 存储请求的结果,从而避免多次请求同一个网页。
  • 支持失败重试的机制
  • 多纬度控制爬取速度(Pipeline、Request、Download、Domain)等等
  • 支持代理池、User Agent 池、Cookies 池
  • 支持爬虫的深度抓取:能够在 Pipeline 中发起深度抓取
  • 支持 URL 去重:使用布隆过滤器
  • Spider 的监控、SpiderEngine 的监控 (基于Etcd、Zookeeper)
  • agent 模块能够对当前服务器的 CPU 和内存进行实时监控
  • SpiderEngine 整合 Quartz

最新版本

模块名 最新版本
netdiscovery-core-core Download
netdiscovery-core-engine Download
netdiscovery-core-engine-monitor Download
netdiscovery-downloader-htmlunit Download
netdiscovery-downloader-httpclient Download
netdiscovery-downloader-okhttp Download
netdiscovery-downloader-selenium Download
netdiscovery-pipeline-couchbase Download
netdiscovery-pipeline-elasticsearch Download
netdiscovery-pipeline-mongo Download
netdiscovery-pipeline-redis Download
netdiscovery-queue-kafka Download
netdiscovery-queue-rabbitmq Download
netdiscovery-queue-redis Download
netdiscovery-queue-rocketmq Download
netdiscovery-kotlin-coroutines Download
netdiscovery-kotlin-dsl Download

NetDiscovery 是基于 Vert.x、RxJava 2 等框架实现的爬虫框架。目前正在不断地完善中,未来会做成一个更为通用的爬虫框架。

对于 Java 工程,如果使用 gradle 构建,由于默认没有使用 jcenter(),需要在相应 module 的 build.gradle 中配置

repositories {
    mavenCentral()
    jcenter()
}

在 NetDiscovery 中,Spider 可以单独运行,Spider 也可以交给 SpiderEngine 来控制。

SpiderEngine 可以在运行之前注册到 Etcd/Zookeeper,然后由 monitor 对 SpiderEngine 进行监控。

Stargazers over time

Stargazers over time

详细功能查看wiki

案例:

基于本人的开源项目

TODO List:

  1. 整合cv4j以及 Tesseract,实现 OCR 识别的功能
  2. 完善协程的模块
  3. SpiderEngine 提供rpc接口
  4. 增加 admin 模块
  5. 支持 Consul
  6. 支持 RxJava 3.x
  7. 完善 wiki,增加各个模式的使用说明
  8. 各个模块能够从配置文件中获取爬虫相应的配置
  9. 增强 HtmlUnit 模块
  10. 增加 chromium 的支持

Contributors:

Contributing:

Pull requests are welcome

联系方式:

Wechat:fengzhizi715

Java与Android技术栈:每周更新推送原创技术文章,欢迎扫描下方的公众号二维码并关注,期待与您的共同成长和进步。

License

Copyright (C) 2017 - present, Tony Shen.

Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at

   http://www.apache.org/licenses/LICENSE-2.0

Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.

netdiscovery's People

Contributors

fengzhizi715 avatar bdqfork avatar otcgate avatar freezaee avatar codacy-badger avatar

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.