GV

GeezerVison

The World Wide Web, restored to 800 pixels of glory.

Home|About|Gaming cabinet|Archives|How it works|Starter sites

On this site

  • Sign in
  • ActionsCI/CD and automation
  • CodespacesCloud development environments
  • All Features
  • Documentation
  • Training
  • Certifications
  • Build with Copilot
  • Customize Copilot
  • Integrations
  • Trending repos
  • GitHub Sponsors
  • Developer articles
  • Enterprises

This view

  • Original page
  • New address

GeezerVison is showing github.com — GitHub - drm/java-linkchecker: HTML link traverser + reporter.

BranchesTags
Open more actions menu

Latest commit

 

History

45 Commits
45 Commits

Folders and files

NameName
Last commit message
Last commit date
lib
lib
 
 
resources
resources
 
 
src
src
 
 
test/nl/melp/linkchecker
test/nl/melp/linkchecker
 
 
LICENSE
LICENSE
 
 
README.md
README.md
 
 
build.sh
build.sh
 
 
log4j.debugging.properties
log4j.debugging.properties
 
 
log4j.properties
log4j.properties
 
 
run.sh
run.sh
 
 
test.sh
test.sh
 
 

Repository files navigation

Simple but efficient HTTP link checker

Project goal

To be able to run a production grade link checker on your own website

  • Avoiding dead links to other websites;
  • Checking the integrity of your own website's pages.

The aim is to be efficient, highly performant, resumable and distributable.

The project was used successfully on websites with up to 300K links.

Usage

./build.sh
java -cp 'lib/*:bin/*.jar' nl.melp.linkchecker.LinkChecker
    [--redis-host=HOST]
    [--redis-port=PORT]
    [--threads=N]
    [--reset|--resume|--recheck]
    [--report|--report-all]
    [--follow-local|--follow-from-local|--no-follow]
    [--recheck-only-errors|--no-recheck]
    [--ignore=PATTERN1[,PATTERN2...] [--ignore=PATTERN3...]]
    [--include=PATTERN1[,PATTERN2...] [--include=PATTERN3...]]
    [--ignore-ssl-errors]
    http://localhost/
    https://localhost/

Available flags and options:

Flag Description
--threads=N Configure number of threads to use. There will be running 1 master thread, 1 logger thread and N worker threads.
--redis-host=HOST Configure HOST as the Redis host.
--redis-port=PORT Configure PORT as the Redis port
--follow-local Only local links to that local* domain are followed
--follow-from-local Only follow links that are mentioned on the local* domain. This means that the link checker only spans over multiple hosts once.
--no-follow No links are followed. This is typically useful in combination with the --recheck flag
--recheck Reset the status for each of the previously failed URLs, and recheck the pages they are mentioned on.
--no-recheck Don't do recheck, even if url's are marked as "processing".
--reset Start with a clean slate
--resume Resume a previously stopped session.
--report When done, write a report to stdout and to reporting keys in Redis.
--report-all Also report working links. By default, only error statuses are reported

*) The start URLs passed in the command line will be considered "local domains". This means that with the flags --follow-from-local, pages read from domains that are part of the arguments list are considered "local" pages and every link mentioned on that page will be followed. Similarly, if the --follow-local flag is passed, only links on the same domain as the domains mentioned in these start urls are followed.

Note that this way you can actually allow multiple domains to be checked, by specifying multiple start urls on different domains.

Resuming state

All status data is stored in Maps and Sets which are persisted in Redis. This means that you can resume a previously started session with different options. If you were crawling a website with the --follow-local or --follow-from-local flags, you must pass the start url as a parameter, so that will be considered a local domain. Note that this doesn't mean that the start URL gets visited again, because the status for that URL is already in memory and therefore will not be checked again.

Running redis

You can easily start Redis using the official Docker repo or install it on your host system. You won't need further configuration.

Issues?

Please report them at github.com/drm/java-linkchecker

Copyright

(c) 2019-2020 Gerard van Helden

About

HTML link traverser + reporter.

Topics

checkercurlhttpjavalinksthreadedwget

Resources

Readme
MIT license
Activity

Stars

3 stars

Watchers

2 watching

Forks

0 forks
Report repository

Releases

Packages

Contributors

Languages

You are visitor 01402503 — GeezerVison does not store the pages you look up.
Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required.