private boolean attemptStart(ServletContext context, String contextName, String contextPath, String paDir, ClassLoader paClassLoader)
{
try
{
context.log(TRY_START_MSG + contextPath);
PortletServices services = JetspeedPortletServices.getSingleton();
if (services != null)
{
PortletApplicationManagement pam =
(PortletApplicationManagement)services.getService("PAM");
if (pam != null && pam.isStarted())
{
DirectoryHelper paDirHelper = new DirectoryHelper(new File(paDir));
pam.startPortletApplication(contextName, contextPath, paDirHelper, paClassLoader);
started = true;
psm = (PortalSessionsManager)services.getService(PortalSessionsManager.SERVICE_NAME);
context.log(STARTED_MSG + contextPath);
return true;
}
}