- Web Script Runtime now takes ServiceRegistry in constructor (not an explicit ever growing list of services)

- default status templates now include Alfresco server information & time of error for diagnostic purposes
- template url.match does not include service context anymore e.g. /alfresco/service/api/path/ is now just /api/path/
- added Retrying Transaction Helper to Service Registry

git-svn-id: https://svn.alfresco.com/repos/alfresco-enterprise/alfresco/HEAD/root@6088 c4b6b30b-aa2e-2d43-bbcb-ca4b014f7261
This commit is contained in:
David Caruana
2007-06-25 12:38:32 +00:00
parent 7bde225592
commit 4ede480475
14 changed files with 51 additions and 43 deletions

View File

@@ -38,6 +38,7 @@ import javax.faces.event.FacesEvent;
import org.alfresco.error.AlfrescoRuntimeException;
import org.alfresco.repo.transaction.RetryingTransactionHelper;
import org.alfresco.service.ServiceRegistry;
import org.alfresco.service.cmr.security.AuthorityService;
import org.alfresco.web.scripts.DeclarativeWebScriptRegistry;
import org.alfresco.web.scripts.WebScriptMatch;
@@ -74,8 +75,7 @@ public class UIWebScript extends SelfRenderingComponent
private boolean scriptUrlModified = false;
private WebScriptRegistry registry;
private RetryingTransactionHelper txnHelper;
private AuthorityService authorityService;
private ServiceRegistry serviceRegistry;;
/**
* Default constructor
@@ -85,8 +85,7 @@ public class UIWebScript extends SelfRenderingComponent
WebApplicationContext ctx = FacesContextUtils.getRequiredWebApplicationContext(
FacesContext.getCurrentInstance());
this.registry = (DeclarativeWebScriptRegistry)ctx.getBean("webscripts.registry");
this.txnHelper = (RetryingTransactionHelper)ctx.getBean("retryingTransactionHelper");
this.authorityService = (AuthorityService)ctx.getBean("authorityService");
this.serviceRegistry = (ServiceRegistry)ctx.getBean(ServiceRegistry.SERVICE_REGISTRY);
}
/**
@@ -279,7 +278,7 @@ public class UIWebScript extends SelfRenderingComponent
WebScriptJSFRuntime(FacesContext fc, String scriptUrl)
{
super(registry, txnHelper, authorityService);
super(registry, serviceRegistry);
this.fc = fc;
this.scriptUrl = scriptUrl;
this.script = WebScriptURLRequest.splitURL(scriptUrl)[2];