mirror of
https://github.com/Alfresco/alfresco-community-repo.git
synced 2025-08-07 17:49:17 +00:00
. Website virtualisation server URL and Port are no longer managed by the web-client-config.xml - instead the values are retrieved dynamically from the VirtServerRegistryMBean.
- Fall back values are used if no virtualisation server is running (with a warning output to the log) - Values are retrieved and cached for 10 seconds - so if the virtualisation server is started after the main Alfresco server then it will take up to 10 seconds for those values to be updated . Adding missing NameMatcher impl to compare() call in AVMBrowseBean git-svn-id: https://svn.alfresco.com/repos/alfresco-enterprise/alfresco/HEAD/root@4602 c4b6b30b-aa2e-2d43-bbcb-ca4b014f7261
This commit is contained in:
@@ -52,6 +52,7 @@ import org.alfresco.service.cmr.workflow.WorkflowService;
|
||||
import org.alfresco.service.namespace.NamespaceService;
|
||||
import org.alfresco.service.namespace.QName;
|
||||
import org.alfresco.service.namespace.RegexQNamePattern;
|
||||
import org.alfresco.util.NameMatcher;
|
||||
import org.alfresco.util.Pair;
|
||||
import org.alfresco.web.app.Application;
|
||||
import org.alfresco.web.app.context.IContextListener;
|
||||
@@ -141,9 +142,6 @@ public class AVMBrowseBean implements IContextListener
|
||||
/** Current AVM Node action context */
|
||||
private AVMNode avmNode = null;
|
||||
|
||||
private String wcmDomain;
|
||||
private String wcmPort;
|
||||
|
||||
/** breadcrumb location */
|
||||
private List<IBreadcrumbHandler> location = null;
|
||||
|
||||
@@ -175,7 +173,10 @@ public class AVMBrowseBean implements IContextListener
|
||||
protected AVMSyncService avmSyncService;
|
||||
|
||||
/** Action service bean reference */
|
||||
protected ActionService actionService;
|
||||
protected ActionService actionService;
|
||||
|
||||
/** Global exclude name matcher */
|
||||
protected NameMatcher nameMatcher;
|
||||
|
||||
|
||||
/**
|
||||
@@ -184,10 +185,6 @@ public class AVMBrowseBean implements IContextListener
|
||||
public AVMBrowseBean()
|
||||
{
|
||||
UIContextService.getInstance(FacesContext.getCurrentInstance()).registerBean(this);
|
||||
|
||||
ClientConfigElement config = Application.getClientConfig(FacesContext.getCurrentInstance());
|
||||
this.wcmDomain = config.getWCMDomain();
|
||||
this.wcmPort = config.getWCMPort();
|
||||
}
|
||||
|
||||
|
||||
@@ -287,6 +284,14 @@ public class AVMBrowseBean implements IContextListener
|
||||
this.actionService = actionService;
|
||||
}
|
||||
|
||||
/**
|
||||
* @param nameMatcher The nameMatcher to set.
|
||||
*/
|
||||
public void setNameMatcher(NameMatcher nameMatcher)
|
||||
{
|
||||
this.nameMatcher = nameMatcher;
|
||||
}
|
||||
|
||||
/**
|
||||
* Summary text for the staging store:
|
||||
* Created On: xx/yy/zz
|
||||
@@ -691,6 +696,9 @@ public class AVMBrowseBean implements IContextListener
|
||||
Map<String, AVMNodeDescriptor> nodes = this.avmService.getDirectoryListing(-1, getCurrentPath());
|
||||
this.files = new ArrayList<Map>(nodes.size());
|
||||
this.folders = new ArrayList<Map>(nodes.size());
|
||||
ClientConfigElement config = Application.getClientConfig(context);
|
||||
String wcmDomain = config.getWCMDomain();
|
||||
String wcmPort = config.getWCMPort();
|
||||
for (String name : nodes.keySet())
|
||||
{
|
||||
AVMNodeDescriptor avmRef = nodes.get(name);
|
||||
@@ -715,7 +723,7 @@ public class AVMBrowseBean implements IContextListener
|
||||
|
||||
// common properties
|
||||
String assetPath = path.substring(rootPathIndex);
|
||||
String previewUrl = AVMConstants.buildAVMAssetUrl(assetPath, this.wcmDomain, this.wcmPort, dns);
|
||||
String previewUrl = AVMConstants.buildAVMAssetUrl(assetPath, wcmDomain, wcmPort, dns);
|
||||
node.getProperties().put("previewUrl", previewUrl);
|
||||
}
|
||||
|
||||
@@ -939,8 +947,8 @@ public class AVMBrowseBean implements IContextListener
|
||||
tx.begin();
|
||||
|
||||
// calcluate the list of differences between the user store and the staging area
|
||||
// TODO Need to pass the global exclude NameMatcher to the compare call.
|
||||
List<AVMDifference> diffs = this.avmSyncService.compare(-1, store + ":/", -1, getStagingStore() + ":/", null);
|
||||
List<AVMDifference> diffs = this.avmSyncService.compare(
|
||||
-1, store + ":/", -1, getStagingStore() + ":/", this.nameMatcher);
|
||||
List<Pair<Integer, String>> versionPaths = new ArrayList<Pair<Integer, String>>();
|
||||
for (AVMDifference diff : diffs)
|
||||
{
|
||||
|
Reference in New Issue
Block a user