mirror of
https://github.com/Alfresco/alfresco-community-repo.git
synced 2025-07-24 17:32:48 +00:00
Merged V2.1 to HEAD
6958: Fix for WCM-823 6959: Merged V1.4 to V2.1 6943: Upgrade scripts for transaction commit time and indexes for QName columns on alf_child_assoc 6960: Fixed script patch "applied on" date updates. 6961: Retry transactions on ConstraintViolationException. 6964: Added svn revision number to be substituted into build string if build number is not passed. 6965: Daylight savings for FTP. Fix for AR-1776. 6966: Added catch blocks for the AVMLockingException. WCM-877. 6967: Interim fix for WCM-866 (large link validation report causes SQL exception) 6968: Fixes for AWC-1309 "Broken preview image for Web Projects in MySpaces" and similar AWC-1635 "Broken/Missing images in MySpaces Web Script". 6970: Force DB write ordering of the NodeStatus vs Node object. 6971: More transaction demarcation fixes for special cases of non-executed script patches. 6972: Switch off session size management for the mass archive and restore test. 6973: Fixed AR-1801: Boolean isMultiValued() no longer returns null git-svn-id: https://svn.alfresco.com/repos/alfresco-enterprise/alfresco/HEAD/root@7370 c4b6b30b-aa2e-2d43-bbcb-ca4b014f7261
This commit is contained in:
@@ -57,6 +57,7 @@ public class LinkValidationAction extends ActionExecuterAbstractBase
|
||||
|
||||
private LinkValidationService linkValidationService;
|
||||
private AVMService avmService;
|
||||
private int maxNumberLinksInReport = -1;
|
||||
|
||||
private static Log logger = LogFactory.getLog(LinkValidationAction.class);
|
||||
|
||||
@@ -80,7 +81,19 @@ public class LinkValidationAction extends ActionExecuterAbstractBase
|
||||
this.avmService = service;
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* Sets the maximum number of links to show in a report
|
||||
*
|
||||
* @param maxLinks The maximum number of links to store in the report,
|
||||
* -1 will store all links but this must be used with
|
||||
* extreme caution as the report is stored as a BLOB
|
||||
* in the underlying database and these have different
|
||||
* maximum sizes
|
||||
*/
|
||||
public void setMaxNumberLinksInReport(int maxLinks)
|
||||
{
|
||||
this.maxNumberLinksInReport = maxLinks;
|
||||
}
|
||||
|
||||
@Override
|
||||
protected void addParameterDefinitions(List<ParameterDefinition> paramList)
|
||||
@@ -136,12 +149,13 @@ public class LinkValidationAction extends ActionExecuterAbstractBase
|
||||
{
|
||||
if (destWebappPath == null)
|
||||
{
|
||||
logger.debug("Performing link validation check for webapp '" + webappPath + "'");
|
||||
logger.debug("Performing link validation check for webapp '" + webappPath + "', storing a maximum of " +
|
||||
this.maxNumberLinksInReport + " broken links");
|
||||
}
|
||||
else
|
||||
{
|
||||
logger.debug("Performing link validation check for webapp '" + webappPath + "', comparing against '" +
|
||||
destWebappPath + "'");
|
||||
destWebappPath + "', storing a maximum of " + this.maxNumberLinksInReport + " broken links");
|
||||
}
|
||||
}
|
||||
|
||||
@@ -160,16 +174,18 @@ public class LinkValidationAction extends ActionExecuterAbstractBase
|
||||
|
||||
// create the report object using the 2 sets of results
|
||||
report = new LinkValidationReport(storeName, webappName, manifest,
|
||||
monitor.getFileUpdateCount(), monitor.getUrlUpdateCount());
|
||||
monitor.getFileUpdateCount(), monitor.getUrlUpdateCount(),
|
||||
this.maxNumberLinksInReport);
|
||||
}
|
||||
else
|
||||
{
|
||||
// retrieve the manifest of all the broken links and files for the webapp
|
||||
HrefManifest manifest = this.linkValidationService.getBrokenHrefManifest(webappPath);
|
||||
|
||||
|
||||
// Create the report object using the link check results
|
||||
report = new LinkValidationReport(storeName, webappName, manifest,
|
||||
manifest.getBaseFileCount(), manifest.getBaseLinkCount());
|
||||
manifest.getBaseFileCount(), manifest.getBaseLinkCount(),
|
||||
this.maxNumberLinksInReport);
|
||||
|
||||
// the monitor object is not used here so manually set
|
||||
// the done status so the client can retrieve the report.
|
||||
|
Reference in New Issue
Block a user