PortletApplicationDeployment deployment = new PortletApplicationDeployment(broadcaster, webApp, metaData);
deploymentMap.put(webApp.getContextPath(), deployment);
deployment.install();
//
PortletApplicationLifeCycle portletApplicationLifeCycle = deployment.getPortletApplicationLifeCycle();
applications.put(portletApplicationLifeCycle.getId(), portletApplicationLifeCycle);
}
finally
{
Thread.currentThread().setContextClassLoader(oldCL);
}