Maven 1.x LinkCheck Plugin

allo 303 and 304 http status to be validated

Details

  • Type: Improvement Improvement
  • Status: Closed Closed
  • Priority: Major Major
  • Resolution: Fixed
  • Affects Version/s: None
  • Fix Version/s: 1.4
  • Component/s: None
  • Labels:
    None
  • Environment:
    maven rc2
  • Number of attachments :
    0

Description

The linkchecker flows MOVED_TEMPORARILY moved links but sikps MOVED_PERMANENTLY while there are as valid as MOVED_TEMPORARILY

example:
http://www.mmbase.org/license

resolution:
add
import org.apache.commons.httpclient.HttpStatus;
to the class imports

in HTTPLinkValidator at row 108 change the code to
if (gm.getStatusCode() == HttpStatus.SC_MOVED_TEMPORARILY || gm.getStatusCode() == HttpStatus.SC_MOVED_PERMANENTLY)

(and a small cleanup )
row 121
if (gm.getStatusCode() == HttpStatus.SC_OK)

Activity

Hide
Carlos Sanchez added a comment -

IMHO is better to report MOVED PERMANENTLY as errors so the user can change the links.

Show
Carlos Sanchez added a comment - IMHO is better to report MOVED PERMANENTLY as errors so the user can change the links.
Hide
Kees Jongenburger added a comment -

I partialy agree. following moved_permanently should not be automatic
Still it's a valid url

Show
Kees Jongenburger added a comment - I partialy agree. following moved_permanently should not be automatic Still it's a valid url
Hide
Arnaud Heritier added a comment -

Fixed with MPLINKCHECK-25

Show
Arnaud Heritier added a comment - Fixed with MPLINKCHECK-25

People

Vote (1)
Watch (1)

Dates

  • Created:
    Updated:
    Resolved:

Time Tracking

Estimated:
10m
Original Estimate - 10 minutes
Remaining:
10m
Remaining Estimate - 10 minutes
Logged:
Not Specified
Time Spent - Not Specified