mirror of
https://github.com/Alfresco/alfresco-community-repo.git
synced 2025-08-14 17:58:59 +00:00
51903 to 54309 git-svn-id: https://svn.alfresco.com/repos/alfresco-enterprise/alfresco/HEAD/root@54310 c4b6b30b-aa2e-2d43-bbcb-ca4b014f7261
32 lines
1.1 KiB
Java
32 lines
1.1 KiB
Java
package org.alfresco.rest.api.tests;
|
|
|
|
import org.apache.chemistry.opencmis.server.impl.atompub.CmisAtomPubServlet;
|
|
import org.eclipse.jetty.servlet.ServletHolder;
|
|
import org.eclipse.jetty.webapp.WebAppContext;
|
|
|
|
/**
|
|
* Manages an embedded jetty server, hooking it up to the repository spring context and providing
|
|
* authenticated, tenant-based access through the tenant servlet.
|
|
*
|
|
* @author steveglover
|
|
*
|
|
*/
|
|
public class EnterpriseJettyComponent extends PublicApiJettyComponent
|
|
{
|
|
public EnterpriseJettyComponent(int port, String contextPath, String[] configLocations, String[] classLocations)
|
|
{
|
|
super(port, contextPath, configLocations, classLocations);
|
|
}
|
|
|
|
@Override
|
|
protected void configureWebAppContext(WebAppContext webAppContext)
|
|
{
|
|
super.configureWebAppContext(webAppContext);
|
|
|
|
// the tenant servlet with alfresco managed authentication
|
|
ServletHolder servletHolder = new ServletHolder(CmisAtomPubServlet.class);
|
|
servletHolder.setInitParameter("callContextHandler", "org.apache.chemistry.opencmis.server.shared.BasicAuthCallContextHandler");
|
|
webAppContext.addServlet(servletHolder, "/cmisatom/*");
|
|
}
|
|
}
|