Skip to content
Konstantinos edited this page Jan 29, 2018 · 22 revisions

This wiki describes how to run the link checker component.


How it works?

The LOM_linkchecker, as part of the ODS project, checks the URL exists in the technical.location element of the IEEE LOM metadata. The program reads a folder contains LOM metadata in XML format and automatically moves those files which include invalid URLs to another folder (let's say broken folder). The file, in our case, is invalid if the HTTP RESPONSE of the URL is not 200. If the file contains an invalid IEEE LOM metadata (e.g., does not include technical.location element) is also moved to the broken folder. We name the file as 'ill-formed'.

Requirement

1- The program is a JAR file and the java JDK should be installed in your machine. JAVA_HOME has to be set in your system as well.


Running the linkchecker

java -jar linkchcker.jar


Results:

When result is 200: the URL is live
When result is 403 or 404: the URL is broken
When result is 500: the URL is unreachable due to the server error
When result is -2: the URL is not a http request (maybe it is a ftp or https request)
When result is -3: the timeout error
When result is -4: the connection was refused by the server
When result is -5: unrecognized error

Log file structure

timestamp repo_name metadata_id Livelink|Dead|Not_well_formed 200

Clone this wiki locally