mirror of
https://github.com/Alfresco/alfresco-community-repo.git
synced 2025-07-24 17:32:48 +00:00
- Links management UI
- Made AJAX polling frequency configurable - Made connection and read timeout values configurable - Added panel around summary area - Removed use of shadowed panels for staging area and user sandboxes git-svn-id: https://svn.alfresco.com/repos/alfresco-enterprise/alfresco/HEAD/root@6061 c4b6b30b-aa2e-2d43-bbcb-ca4b014f7261
This commit is contained in:
@@ -521,6 +521,15 @@
|
|||||||
<property name="publicAction">
|
<property name="publicAction">
|
||||||
<value>false</value>
|
<value>false</value>
|
||||||
</property>
|
</property>
|
||||||
|
<property name="noThreads">
|
||||||
|
<value>5</value>
|
||||||
|
</property>
|
||||||
|
<property name="connectionTimeout">
|
||||||
|
<value>10000</value>
|
||||||
|
</property>
|
||||||
|
<property name="readTimeout">
|
||||||
|
<value>30000</value>
|
||||||
|
</property>
|
||||||
</bean>
|
</bean>
|
||||||
|
|
||||||
<!-- Scheduled action helper beans -->
|
<!-- Scheduled action helper beans -->
|
||||||
|
@@ -55,6 +55,9 @@ public class LinkValidationAction extends ActionExecuterAbstractBase
|
|||||||
public static final String PARAM_COMPARE_TO_STAGING = "compare-to-staging";
|
public static final String PARAM_COMPARE_TO_STAGING = "compare-to-staging";
|
||||||
public static final String PARAM_MONITOR = "monitor";
|
public static final String PARAM_MONITOR = "monitor";
|
||||||
|
|
||||||
|
private int noThreads = 5;
|
||||||
|
private int readTimeout = 30000;
|
||||||
|
private int connectionTimeout = 10000;
|
||||||
private LinkValidationService linkValidationService;
|
private LinkValidationService linkValidationService;
|
||||||
private AVMService avmService;
|
private AVMService avmService;
|
||||||
|
|
||||||
@@ -79,6 +82,36 @@ public class LinkValidationAction extends ActionExecuterAbstractBase
|
|||||||
{
|
{
|
||||||
this.avmService = service;
|
this.avmService = service;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Sets the number of millseconds to wait for a connection
|
||||||
|
*
|
||||||
|
* @param connectionTimeout Number of milliseconds to wait for connection
|
||||||
|
*/
|
||||||
|
public void setConnectionTimeout(int connectionTimeout)
|
||||||
|
{
|
||||||
|
this.connectionTimeout = connectionTimeout;
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Sets the number of milliseconds to wait for a response
|
||||||
|
*
|
||||||
|
* @param readTimeout Number of milliseconds to wait for a response
|
||||||
|
*/
|
||||||
|
public void setReadTimeout(int readTimeout)
|
||||||
|
{
|
||||||
|
this.readTimeout = readTimeout;
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Sets the number of threads to use to gather broken links
|
||||||
|
*
|
||||||
|
* @param threads Number of threads to use to gather broken links
|
||||||
|
*/
|
||||||
|
public void setNoThreads(int threads)
|
||||||
|
{
|
||||||
|
this.noThreads = threads;
|
||||||
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
protected void addParameterDefinitions(List<ParameterDefinition> paramList)
|
protected void addParameterDefinitions(List<ParameterDefinition> paramList)
|
||||||
@@ -151,7 +184,7 @@ public class LinkValidationAction extends ActionExecuterAbstractBase
|
|||||||
{
|
{
|
||||||
// get the object to represent the broken files
|
// get the object to represent the broken files
|
||||||
HrefDifference hdiff = this.linkValidationService.getHrefDifference(webappPath, destWebappPath,
|
HrefDifference hdiff = this.linkValidationService.getHrefDifference(webappPath, destWebappPath,
|
||||||
10000, 30000, 5, monitor);
|
this.connectionTimeout, this.readTimeout, this.noThreads, monitor);
|
||||||
|
|
||||||
// get the broken files created due to deletions and new/modified files
|
// get the broken files created due to deletions and new/modified files
|
||||||
HrefManifest brokenByDelete = this.linkValidationService.getHrefManifestBrokenByDelete(hdiff);
|
HrefManifest brokenByDelete = this.linkValidationService.getHrefManifestBrokenByDelete(hdiff);
|
||||||
@@ -164,7 +197,8 @@ public class LinkValidationAction extends ActionExecuterAbstractBase
|
|||||||
{
|
{
|
||||||
// firstly call updateHrefInfo to scan the whole store for broken links
|
// firstly call updateHrefInfo to scan the whole store for broken links
|
||||||
// NOTE: currently this is NOT done incrementally
|
// NOTE: currently this is NOT done incrementally
|
||||||
this.linkValidationService.updateHrefInfo(webappPath, false, 10000, 30000, 5, monitor);
|
this.linkValidationService.updateHrefInfo(webappPath, false, this.connectionTimeout,
|
||||||
|
this.readTimeout, this.noThreads, monitor);
|
||||||
|
|
||||||
// retrieve the manifest of all the broken links and files for the webapp
|
// retrieve the manifest of all the broken links and files for the webapp
|
||||||
List<HrefManifestEntry> manifests = this.linkValidationService.getBrokenHrefManifestEntries(webappPath);
|
List<HrefManifestEntry> manifests = this.linkValidationService.getBrokenHrefManifestEntries(webappPath);
|
||||||
|
Reference in New Issue
Block a user