- 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:
Gavin Cornwell
2007-06-21 22:19:13 +00:00
parent 1f708bd86a
commit ad3ced0367
2 changed files with 45 additions and 2 deletions

View File

@@ -521,6 +521,15 @@
<property name="publicAction">
<value>false</value>
</property>
<property name="noThreads">
<value>5</value>
</property>
<property name="connectionTimeout">
<value>10000</value>
</property>
<property name="readTimeout">
<value>30000</value>
</property>
</bean>
<!-- Scheduled action helper beans -->

View File

@@ -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_MONITOR = "monitor";
private int noThreads = 5;
private int readTimeout = 30000;
private int connectionTimeout = 10000;
private LinkValidationService linkValidationService;
private AVMService avmService;
@@ -79,6 +82,36 @@ public class LinkValidationAction extends ActionExecuterAbstractBase
{
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
protected void addParameterDefinitions(List<ParameterDefinition> paramList)
@@ -151,7 +184,7 @@ public class LinkValidationAction extends ActionExecuterAbstractBase
{
// get the object to represent the broken files
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
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
// 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
List<HrefManifestEntry> manifests = this.linkValidationService.getBrokenHrefManifestEntries(webappPath);