portals-jetspeed-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Scott T Weaver <scotts-jetspeed-l...@binary-designs.net>
Subject Re: [J2] Using FileSystem PAM from web app class loader
Date Mon, 21 Jun 2004 17:38:06 GMT
Ate and Serge,

Ate, I am seeing the identical issue here that you are and am trying to
fix it.  I am glad you are experiencing the same issue, because I
thought I was going mad ;)

I am working on this right now so I will hopefully have a solution in
the next couple of hours.

On Mon, 2004-06-21 at 13:27, Ate Douma wrote:
> Serge and Scott,
> 
> I can confirm to have similar problems. Not the same though.
> If I do a allClean allBuild quickStart and then start Tomcat
> it all works perfectly. I can access all the portlets without any problem.
> It goes wrong though when I stop/start Tomcat again. Then I get the following
> stacktrace (in jetspeed.log and on screen) when opening the J2 portal site again:
> 
> 2004-06-21 19:20:28,515 [http8080-Processor3] DEBUG org.apache.jetspeed.container.JetspeedContainerServlet
- Rendering: 
> Portlet Class = org.apache.jetspeed.portlets.layout.MultiColumnPortlet
> 2004-06-21 19:20:28,515 [http8080-Processor3] ERROR org.apache.jetspeed.container.JetspeedContainerServlet
- Error 
> rendering portlet "VelocityTwoColumns": java.lang.NoClassDefFoundError
> java.lang.NoClassDefFoundError
> 	at org.apache.jetspeed.components.portletentity.PortletEntityImpl.getPreferenceSet(PortletEntityImpl.java:128)
> 	at org.apache.pluto.core.impl.PortletPreferencesImpl.<init>(PortletPreferencesImpl.java:72)
> 	at org.apache.pluto.factory.impl.PortletPreferencesFactoryImpl.getPortletPreferences(PortletPreferencesFactoryImpl.java:39)
> 	at org.apache.pluto.factory.PortletObjectAccess.getPortletPreferences(PortletObjectAccess.java:116)
> 	at org.apache.pluto.core.impl.RenderRequestImpl.getPreferences(RenderRequestImpl.java:74)
> 	at org.apache.jetspeed.portlets.layout.LayoutPortlet.doView(LayoutPortlet.java:72)
> 	at org.apache.jetspeed.portlets.layout.MultiColumnPortlet.doView(MultiColumnPortlet.java:82)
> 	at javax.portlet.GenericPortlet.doDispatch(GenericPortlet.java:247)
> 	at javax.portlet.GenericPortlet.render(GenericPortlet.java:175)
> 	at org.apache.jetspeed.container.JetspeedContainerServlet.doGet(JetspeedContainerServlet.java:214)
> 	at javax.servlet.http.HttpServlet.service(HttpServlet.java:740)
> 	at javax.servlet.http.HttpServlet.service(HttpServlet.java:853)
> 	at org.apache.catalina.core.ApplicationDispatcher.invoke(ApplicationDispatcher.java:684)
> 	at org.apache.catalina.core.ApplicationDispatcher.doInclude(ApplicationDispatcher.java:575)
> 	at org.apache.catalina.core.ApplicationDispatcher.include(ApplicationDispatcher.java:498)
> 	at org.apache.jetspeed.container.invoker.ServletPortletInvoker.invoke(ServletPortletInvoker.java:208)
> 	at org.apache.jetspeed.container.invoker.ServletPortletInvoker.render(ServletPortletInvoker.java:122)
> 	at org.apache.pluto.PortletContainerImpl.renderPortlet(PortletContainerImpl.java:103)
> 	at org.apache.jetspeed.container.JetspeedPortletContainerWrapper.renderPortlet(JetspeedPortletContainerWrapper.java:97)
> 	at org.apache.jetspeed.aggregator.impl.PortletRendererImpl.renderNow(PortletRendererImpl.java:95)
> 	at org.apache.jetspeed.aggregator.impl.PageAggregatorImpl.build(PageAggregatorImpl.java:231)
> 	at org.apache.jetspeed.aggregator.AggregatorValve.invoke(AggregatorValve.java:47)
> 	at org.apache.jetspeed.pipeline.JetspeedPipeline.invokeNext(JetspeedPipeline.java:255)
> 	at org.apache.jetspeed.pipeline.valve.impl.ActionValveImpl.invoke(ActionValveImpl.java:107)
> 	at org.apache.jetspeed.pipeline.JetspeedPipeline.invokeNext(JetspeedPipeline.java:255)
> 	at org.apache.jetspeed.container.ContainerValve.invoke(ContainerValve.java:76)
> 	at org.apache.jetspeed.pipeline.JetspeedPipeline.invokeNext(JetspeedPipeline.java:255)
> 	at org.apache.jetspeed.profiler.impl.ProfilerValveImpl.invoke(ProfilerValveImpl.java:57)
> 	at org.apache.jetspeed.pipeline.JetspeedPipeline.invokeNext(JetspeedPipeline.java:255)
> 	at org.apache.jetspeed.security.impl.SecurityValveImpl.invoke(SecurityValveImpl.java:89)
> 	at org.apache.jetspeed.pipeline.JetspeedPipeline.invokeNext(JetspeedPipeline.java:255)
> 	at org.apache.jetspeed.capabilities.impl.CapabilityValveImpl.invoke(CapabilityValveImpl.java:132)
> 	at org.apache.jetspeed.pipeline.JetspeedPipeline.invokeNext(JetspeedPipeline.java:255)
> 	at org.apache.jetspeed.localization.impl.LocalizationValveImpl.invoke(LocalizationValveImpl.java:62)
> 	at org.apache.jetspeed.pipeline.JetspeedPipeline.invokeNext(JetspeedPipeline.java:255)
> 	at org.apache.jetspeed.pipeline.JetspeedPipeline.invoke(JetspeedPipeline.java:237)
> 	at org.apache.jetspeed.engine.JetspeedEngine.service(JetspeedEngine.java:276)
> 	at org.apache.jetspeed.engine.JetspeedServlet.doGet(JetspeedServlet.java:207)
> 	at javax.servlet.http.HttpServlet.service(HttpServlet.java:740)
> 	at javax.servlet.http.HttpServlet.service(HttpServlet.java:853)
> 	at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:247)
> 	at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:193)
> 	at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:256)
> 	at org.apache.catalina.core.StandardPipeline$StandardPipelineValveContext.invokeNext(StandardPipeline.java:643)
> 	at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:480)
> 	at org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:995)
> 	at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:191)
> 	at org.apache.catalina.core.StandardPipeline$StandardPipelineValveContext.invokeNext(StandardPipeline.java:643)
> 	at org.apache.catalina.authenticator.AuthenticatorBase.invoke(AuthenticatorBase.java:492)
> 	at org.apache.catalina.core.StandardPipeline$StandardPipelineValveContext.invokeNext(StandardPipeline.java:641)
> 	at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:480)
> 	at org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:995)
> 	at org.apache.catalina.core.StandardContext.invoke(StandardContext.java:2422)
> 	at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:180)
> 	at org.apache.catalina.core.StandardPipeline$StandardPipelineValveContext.invokeNext(StandardPipeline.java:643)
> 	at org.apache.catalina.valves.ErrorDispatcherValve.invoke(ErrorDispatcherValve.java:171)
> 	at org.apache.catalina.core.StandardPipeline$StandardPipelineValveContext.invokeNext(StandardPipeline.java:641)
> 	at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:163)
> 	at org.apache.catalina.core.StandardPipeline$StandardPipelineValveContext.invokeNext(StandardPipeline.java:641)
> 	at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:480)
> 	at org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:995)
> 	at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:174)
> 	at org.apache.catalina.core.StandardPipeline$StandardPipelineValveContext.invokeNext(StandardPipeline.java:643)
> 	at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:480)
> 	at org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:995)
> 	at org.apache.coyote.tomcat4.CoyoteAdapter.service(CoyoteAdapter.java:199)
> 	at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:828)
> 	at org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.processConnection(Http11Protocol.java:700)
> 	at org.apache.tomcat.util.net.TcpWorkerThread.runIt(PoolTcpEndpoint.java:584)
> 	at org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPool.java:683)
> 	at java.lang.Thread.run(Thread.java:534)
> 
> My setup is almost the same as from Scott. But, maybe important, I use a more recent
JDK:
> 
> Latest J2 CVS HEAD
> Windows XP SP1
> Sun J2SE 1.4.2_04
> Tomcat 4.1.30
> Oracle 9i
> 
> 
> Serge Huber wrote:
> > 
> > I forgot to mention my environment :
> > 
> > - latest J2 from CVS HEAD, including Ate's properties change
> > - Windows XP SP 1
> > - Sun JDK 1.4.2_01
> > - Tomcat 4.1.30
> > 
> > My guess about this problem is that as the JVM's Preferences impl uses 
> > the system class loader (see my previous mail), we cannot access the 
> > PreferencesFactoryImpl which is in a child class loader (the webapp's 
> > class loader). Now I would love to be able to propose a workaround, but 
> > since this seems to be a problem with the JDK's implementation and 
> > doesn't offer an alternate way to set a class loader, I'm not sure there 
> > are any options...
> > 
> > Anyway, it might also just be my setup. Can somebody reproduce this 
> > problem ?
> > 
> > Regards,
> >   Serge Huber.
> > 
> > At 18:44 21.06.2004, you wrote:
> > 
> >> Scott,
> >>
> >> I did a complete checkout of J2, then :
> >>
> >> allClean
> >> allBuild
> >> quickStart
> >>
> >> and then started Tomcat, here is the log of what happened :
> >>
> >>  INFO: Preparing to deploy portlet app "HW_App"
> >>  INFO: Deploying portlet applicaion WAR demo.war
> >>  INFO: Portlet application deployment target directory is 
> >> C:\java\technologies\jakarta-tomcat\webapps/HW_App
> >> java.lang.InternalError: Can't instantiate Preferences factory 
> >> java.lang.ClassNotFoundException: 
> >> org.apache.jetspeed.prefs.impl.PreferencesFactoryImpl
> >>         at java.util.prefs.Preferences.<clinit>(Preferences.java:204)
> >>         at 
> >> org.apache.jetspeed.om.preference.impl.PrefsPreference.createPrefenceNode(PrefsPreference.java:540)

> >>
> >>         at 
> >> org.apache.jetspeed.om.preference.impl.PrefsPreference.<init>(PrefsPreference.java:73)

> >>
> >>         at 
> >> org.apache.jetspeed.util.descriptor.PortletPreferenceRule.end(PortletPreferenceRule.java:74)

> >>
> >>         at 
> >> org.apache.commons.digester.Digester.endElement(Digester.java:1058)
> >>         at 
> >> org.apache.xerces.parsers.AbstractSAXParser.endElement(Unknown Source)
> >>         at 
> >> org.apache.xerces.impl.XMLDocumentFragmentScannerImpl.scanEndElement(Unknown

> >> Source)
> >>         at 
> >> org.apache.xerces.impl.XMLDocumentFragmentScannerImpl$FragmentContentDispatcher.dispatch(Unknown

> >> Source)
> >>         at 
> >> org.apache.xerces.impl.XMLDocumentFragmentScannerImpl.scanDocument(Unknown 
> >>   Source)
> >>         at org.apache.xerces.parsers.DTDConfiguration.parse(Unknown 
> >> Source)
> >>         at org.apache.xerces.parsers.DTDConfiguration.parse(Unknown 
> >> Source)
> >>         at org.apache.xerces.parsers.XMLParser.parse(Unknown Source)
> >>         at org.apache.xerces.parsers.AbstractSAXParser.parse(Unknown 
> >> Source)
> >>         at org.apache.commons.digester.Digester.parse(Digester.java:1586)
> >>         at 
> >> org.apache.jetspeed.util.descriptor.PortletApplicationDescriptor.createPortletApplication(PortletApplicationDescriptor.java:146)

> >>
> >>         at 
> >> org.apache.jetspeed.util.descriptor.PortletApplicationWar.createPortletApp(PortletApplicationWar.java:213)

> >>
> >>         at 
> >> org.apache.jetspeed.tools.pamanager.FileSystemPAM.registerApplication(FileSystemPAM.java:346)

> >>
> >>         at 
> >> org.apache.jetspeed.tools.pamanager.FileSystemPAM.sysDeploy(FileSystemPAM.java:297)

> >>
> >>         at 
> >> org.apache.jetspeed.tools.pamanager.FileSystemPAM.deploy(FileSystemPAM.java:89)

> >>
> >>         at 
> >> org.apache.jetspeed.tools.pamanager.CatalinaPAM.deploy(CatalinaPAM.java:76)

> >>
> >>         at 
> >> org.apache.jetspeed.deployment.impl.DeployPortletAppEventListener.invoke(DeployPortletAppEventListener.java:114)

> >>
> >>         at 
> >> org.apache.jetspeed.deployment.DeploymentEventDispatcher.dispatch(DeploymentEventDispatcher.java:64)

> >>
> >>         at 
> >> org.apache.jetspeed.deployment.fs.FileSystemScanner.deployNewArtifacts(FileSystemScanner.java:125)

> >>
> >>         at 
> >> org.apache.jetspeed.deployment.fs.FileSystemScanner.run(FileSystemScanner.java:88)

> >>
> >> ERROR: Unable to register portlet application, HW_App, through the 
> >> portlet registry: 
> >> org.apache.jetspeed.tools.pamanager.PortletApplicationException: Could 
> >> not
> >> unmarshal portlet.xml. java.lang.InternalError: Can't instantiate 
> >> Preferences factory java.lang.ClassNotFoundException: 
> >> org.apache.jetspeed.prefs.impl.Preferenc
> >> esFactoryImpl
> >> org.apache.jetspeed.tools.pamanager.PortletApplicationException: Could 
> >> not unmarshal portlet.xml. java.lang.InternalError: Can't instantiate 
> >> Preferences factory
> >>  java.lang.ClassNotFoundException: 
> >> org.apache.jetspeed.prefs.impl.PreferencesFactoryImpl
> >>         at 
> >> org.apache.jetspeed.util.descriptor.PortletApplicationDescriptor.createPortletApplication(PortletApplicationDescriptor.java:172)

> >>
> >>         at 
> >> org.apache.jetspeed.util.descriptor.PortletApplicationWar.createPortletApp(PortletApplicationWar.java:213)

> >>
> >>         at 
> >> org.apache.jetspeed.tools.pamanager.FileSystemPAM.registerApplication(FileSystemPAM.java:346)

> >>
> >>         at 
> >> org.apache.jetspeed.tools.pamanager.FileSystemPAM.sysDeploy(FileSystemPAM.java:297)

> >>
> >>         at 
> >> org.apache.jetspeed.tools.pamanager.FileSystemPAM.deploy(FileSystemPAM.java:89)

> >>
> >>         at 
> >> org.apache.jetspeed.tools.pamanager.CatalinaPAM.deploy(CatalinaPAM.java:76)

> >>
> >>         at 
> >> org.apache.jetspeed.deployment.impl.DeployPortletAppEventListener.invoke(DeployPortletAppEventListener.java:114)

> >>
> >>         at 
> >> org.apache.jetspeed.deployment.DeploymentEventDispatcher.dispatch(DeploymentEventDispatcher.java:64)

> >>
> >>         at 
> >> org.apache.jetspeed.deployment.fs.FileSystemScanner.deployNewArtifacts(FileSystemScanner.java:125)

> >>
> >>         at 
> >> org.apache.jetspeed.deployment.fs.FileSystemScanner.run(FileSystemScanner.java:88)

> >>
> >> Caused by: java.lang.InternalError: Can't instantiate Preferences 
> >> factory java.lang.ClassNotFoundException: 
> >> org.apache.jetspeed.prefs.impl.PreferencesFactoryImp
> >> l
> >>         at java.util.prefs.Preferences.<clinit>(Preferences.java:204)
> >>         at 
> >> org.apache.jetspeed.om.preference.impl.PrefsPreference.createPrefenceNode(PrefsPreference.java:540)

> >>
> >>         at 
> >> org.apache.jetspeed.om.preference.impl.PrefsPreference.<init>(PrefsPreference.java:73)

> >>
> >>         at 
> >> org.apache.jetspeed.util.descriptor.PortletPreferenceRule.end(PortletPreferenceRule.java:74)

> >>
> >>         at 
> >> org.apache.commons.digester.Digester.endElement(Digester.java:1058)
> >>         at 
> >> org.apache.xerces.parsers.AbstractSAXParser.endElement(Unknown Source)
> >>         at 
> >> org.apache.xerces.impl.XMLDocumentFragmentScannerImpl.scanEndElement(Unknown

> >> Source)
> >>         at 
> >> org.apache.xerces.impl.XMLDocumentFragmentScannerImpl$FragmentContentDispatcher.dispatch(Unknown

> >> Source)
> >>         at 
> >> org.apache.xerces.impl.XMLDocumentFragmentScannerImpl.scanDocument(Unknown 
> >>   Source)
> >>         at org.apache.xerces.parsers.DTDConfiguration.parse(Unknown 
> >> Source)
> >>         at org.apache.xerces.parsers.DTDConfiguration.parse(Unknown 
> >> Source)
> >>         at org.apache.xerces.parsers.XMLParser.parse(Unknown Source)
> >>         at org.apache.xerces.parsers.AbstractSAXParser.parse(Unknown 
> >> Source)
> >>         at org.apache.commons.digester.Digester.parse(Digester.java:1586)
> >>         at 
> >> org.apache.jetspeed.util.descriptor.PortletApplicationDescriptor.createPortletApplication(PortletApplicationDescriptor.java:146)

> >>
> >>         ... 9 more
> >> ERROR: Unexpected exception deploying portlet application: 
> >> org.apache.jetspeed.components.portletregistry.RegistryException: 
> >> Unable to register portlet applicat
> >> ion, HW_App, through the portlet registry: 
> >> org.apache.jetspeed.tools.pamanager.PortletApplicationException: Could 
> >> not unmarshal portlet.xml. java.lang.InternalE
> >> rror: Can't instantiate Preferences factory 
> >> java.lang.ClassNotFoundException: 
> >> org.apache.jetspeed.prefs.impl.PreferencesFactoryImpl attempting 
> >> rollback...
> >> org.apache.jetspeed.components.portletregistry.RegistryException: 
> >> Unable to register portlet application, HW_App, through the portlet 
> >> registry: org.apache.jetsp
> >> eed.tools.pamanager.PortletApplicationException: Could not unmarshal 
> >> portlet.xml. java.lang.InternalError: Can't instantiate Preferences 
> >> factory java.lang.Class
> >> NotFoundException: org.apache.jetspeed.prefs.impl.PreferencesFactoryImpl
> >>         at 
> >> org.apache.jetspeed.tools.pamanager.FileSystemPAM.registerApplication(FileSystemPAM.java:383)

> >>
> >>         at 
> >> org.apache.jetspeed.tools.pamanager.FileSystemPAM.sysDeploy(FileSystemPAM.java:297)

> >>
> >>         at 
> >> org.apache.jetspeed.tools.pamanager.FileSystemPAM.deploy(FileSystemPAM.java:89)

> >>
> >>         at 
> >> org.apache.jetspeed.tools.pamanager.CatalinaPAM.deploy(CatalinaPAM.java:76)

> >>
> >>         at 
> >> org.apache.jetspeed.deployment.impl.DeployPortletAppEventListener.invoke(DeployPortletAppEventListener.java:114)

> >>
> >>         at 
> >> org.apache.jetspeed.deployment.DeploymentEventDispatcher.dispatch(DeploymentEventDispatcher.java:64)

> >>
> >>         at 
> >> org.apache.jetspeed.deployment.fs.FileSystemScanner.deployNewArtifacts(FileSystemScanner.java:125)

> >>
> >>         at 
> >> org.apache.jetspeed.deployment.fs.FileSystemScanner.run(FileSystemScanner.java:88)

> >>
> >> Caused by: 
> >> org.apache.jetspeed.tools.pamanager.PortletApplicationException: Could 
> >> not unmarshal portlet.xml. java.lang.InternalError: Can't instantiate 
> >> Preferen
> >> ces factory java.lang.ClassNotFoundException: 
> >> org.apache.jetspeed.prefs.impl.PreferencesFactoryImpl
> >>         at 
> >> org.apache.jetspeed.util.descriptor.PortletApplicationDescriptor.createPortletApplication(PortletApplicationDescriptor.java:172)

> >>
> >>         at 
> >> org.apache.jetspeed.util.descriptor.PortletApplicationWar.createPortletApp(PortletApplicationWar.java:213)

> >>
> >>         at 
> >> org.apache.jetspeed.tools.pamanager.FileSystemPAM.registerApplication(FileSystemPAM.java:346)

> >>
> >>         ... 7 more
> >> Caused by: java.lang.InternalError: Can't instantiate Preferences 
> >> factory java.lang.ClassNotFoundException: 
> >> org.apache.jetspeed.prefs.impl.PreferencesFactoryImp
> >> l
> >>         at java.util.prefs.Preferences.<clinit>(Preferences.java:204)
> >>         at 
> >> org.apache.jetspeed.om.preference.impl.PrefsPreference.createPrefenceNode(PrefsPreference.java:540)

> >>
> >>         at 
> >> org.apache.jetspeed.om.preference.impl.PrefsPreference.<init>(PrefsPreference.java:73)

> >>
> >>         at 
> >> org.apache.jetspeed.util.descriptor.PortletPreferenceRule.end(PortletPreferenceRule.java:74)

> >>
> >>         at 
> >> org.apache.commons.digester.Digester.endElement(Digester.java:1058)
> >>         at 
> >> org.apache.xerces.parsers.AbstractSAXParser.endElement(Unknown Source)
> >>         at 
> >> org.apache.xerces.impl.XMLDocumentFragmentScannerImpl.scanEndElement(Unknown

> >> Source)
> >>         at 
> >> org.apache.xerces.impl.XMLDocumentFragmentScannerImpl$FragmentContentDispatcher.dispatch(Unknown

> >> Source)
> >>         at 
> >> org.apache.xerces.impl.XMLDocumentFragmentScannerImpl.scanDocument(Unknown 
> >>   Source)
> >>         at org.apache.xerces.parsers.DTDConfiguration.parse(Unknown 
> >> Source)
> >>         at org.apache.xerces.parsers.DTDConfiguration.parse(Unknown 
> >> Source)
> >>         at org.apache.xerces.parsers.XMLParser.parse(Unknown Source)
> >>         at org.apache.xerces.parsers.AbstractSAXParser.parse(Unknown 
> >> Source)
> >>         at org.apache.commons.digester.Digester.parse(Digester.java:1586)
> >>         at 
> >> org.apache.jetspeed.util.descriptor.PortletApplicationDescriptor.createPortletApplication(PortletApplicationDescriptor.java:146)

> >>
> >>         ... 9 more
> >>  INFO: Exception in deploy. Rollback of application deployment...
> >>  INFO: Rollback: Remove 
> >> C:\java\technologies\jakarta-tomcat\webapps/HW_App and all 
> >> sub-directories.
> >> ERROR: org.apache.jetspeed.deployment.DeploymentException: Error 
> >> deploying portlet app: 
> >> org.apache.jetspeed.tools.pamanager.PortletApplicationException: org.apa
> >> che.jetspeed.components.portletregistry.RegistryException: Unable to 
> >> register portlet application, HW_App, through the portlet registry: 
> >> org.apache.jetspeed.too
> >> ls.pamanager.PortletApplicationException: Could not unmarshal 
> >> portlet.xml. java.lang.InternalError: Can't instantiate Preferences 
> >> factory java.lang.ClassNotFoun
> >> dException: org.apache.jetspeed.prefs.impl.PreferencesFactoryImpl
> >> org.apache.jetspeed.deployment.DeploymentException: Error deploying 
> >> portlet app: 
> >> org.apache.jetspeed.tools.pamanager.PortletApplicationException: 
> >> org.apache.jet
> >> speed.components.portletregistry.RegistryException: Unable to register 
> >> portlet application, HW_App, through the portlet registry: 
> >> org.apache.jetspeed.tools.pama
> >> nager.PortletApplicationException: Could not unmarshal portlet.xml. 
> >> java.lang.InternalError: Can't instantiate Preferences factory 
> >> java.lang.ClassNotFoundExcept
> >> ion: org.apache.jetspeed.prefs.impl.PreferencesFactoryImpl
> >>         at 
> >> org.apache.jetspeed.deployment.impl.DeployPortletAppEventListener.invoke(DeployPortletAppEventListener.java:128)

> >>
> >>         at 
> >> org.apache.jetspeed.deployment.DeploymentEventDispatcher.dispatch(DeploymentEventDispatcher.java:64)

> >>
> >>         at 
> >> org.apache.jetspeed.deployment.fs.FileSystemScanner.deployNewArtifacts(FileSystemScanner.java:125)

> >>
> >>         at 
> >> org.apache.jetspeed.deployment.fs.FileSystemScanner.run(FileSystemScanner.java:88)

> >>
> >> Caused by: 
> >> org.apache.jetspeed.tools.pamanager.PortletApplicationException: 
> >> org.apache.jetspeed.components.portletregistry.RegistryException: 
> >> Unable to register
> >>  portlet application, HW_App, through the portlet registry: 
> >> org.apache.jetspeed.tools.pamanager.PortletApplicationException: Could 
> >> not unmarshal portlet.xml. ja
> >> va.lang.InternalError: Can't instantiate Preferences factory 
> >> java.lang.ClassNotFoundException: 
> >> org.apache.jetspeed.prefs.impl.PreferencesFactoryImpl
> >>         at 
> >> org.apache.jetspeed.tools.pamanager.FileSystemPAM.sysDeploy(FileSystemPAM.java:319)

> >>
> >>         at 
> >> org.apache.jetspeed.tools.pamanager.FileSystemPAM.deploy(FileSystemPAM.java:89)

> >>
> >>         at 
> >> org.apache.jetspeed.tools.pamanager.CatalinaPAM.deploy(CatalinaPAM.java:76)

> >>
> >>         at 
> >> org.apache.jetspeed.deployment.impl.DeployPortletAppEventListener.invoke(DeployPortletAppEventListener.java:114)

> >>
> >>         ... 3 more
> >> Caused by: 
> >> org.apache.jetspeed.components.portletregistry.RegistryException: 
> >> Unable to register portlet application, HW_App, through the portlet 
> >> registry: org.a
> >> pache.jetspeed.tools.pamanager.PortletApplicationException: Could not 
> >> unmarshal portlet.xml. java.lang.InternalError: Can't instantiate 
> >> Preferences factory java
> >> .lang.ClassNotFoundException: 
> >> org.apache.jetspeed.prefs.impl.PreferencesFactoryImpl
> >>         at 
> >> org.apache.jetspeed.tools.pamanager.FileSystemPAM.registerApplication(FileSystemPAM.java:383)

> >>
> >>         at 
> >> org.apache.jetspeed.tools.pamanager.FileSystemPAM.sysDeploy(FileSystemPAM.java:297)

> >>
> >>         ... 6 more
> >> Caused by: 
> >> org.apache.jetspeed.tools.pamanager.PortletApplicationException: Could 
> >> not unmarshal portlet.xml. java.lang.InternalError: Can't instantiate 
> >> Preferen
> >> ces factory java.lang.ClassNotFoundException: 
> >> org.apache.jetspeed.prefs.impl.PreferencesFactoryImpl
> >>         at 
> >> org.apache.jetspeed.util.descriptor.PortletApplicationDescriptor.createPortletApplication(PortletApplicationDescriptor.java:172)

> >>
> >>         at 
> >> org.apache.jetspeed.util.descriptor.PortletApplicationWar.createPortletApp(PortletApplicationWar.java:213)

> >>
> >>         at 
> >> org.apache.jetspeed.tools.pamanager.FileSystemPAM.registerApplication(FileSystemPAM.java:346)

> >>
> >>         ... 7 more
> >> Caused by: java.lang.InternalError: Can't instantiate Preferences 
> >> factory java.lang.ClassNotFoundException: 
> >> org.apache.jetspeed.prefs.impl.PreferencesFactoryImp
> >> l
> >>         at java.util.prefs.Preferences.<clinit>(Preferences.java:204)
> >>         at 
> >> org.apache.jetspeed.om.preference.impl.PrefsPreference.createPrefenceNode(PrefsPreference.java:540)

> >>
> >>         at 
> >> org.apache.jetspeed.om.preference.impl.PrefsPreference.<init>(PrefsPreference.java:73)

> >>
> >>         at 
> >> org.apache.jetspeed.util.descriptor.PortletPreferenceRule.end(PortletPreferenceRule.java:74)

> >>
> >>         at 
> >> org.apache.commons.digester.Digester.endElement(Digester.java:1058)
> >>         at 
> >> org.apache.xerces.parsers.AbstractSAXParser.endElement(Unknown Source)
> >>         at 
> >> org.apache.xerces.impl.XMLDocumentFragmentScannerImpl.scanEndElement(Unknown

> >> Source)
> >>         at 
> >> org.apache.xerces.impl.XMLDocumentFragmentScannerImpl$FragmentContentDispatcher.dispatch(Unknown

> >> Source)
> >>         at 
> >> org.apache.xerces.impl.XMLDocumentFragmentScannerImpl.scanDocument(Unknown 
> >>   Source)
> >>         at org.apache.xerces.parsers.DTDConfiguration.parse(Unknown 
> >> Source)
> >>         at org.apache.xerces.parsers.DTDConfiguration.parse(Unknown 
> >> Source)
> >>         at org.apache.xerces.parsers.XMLParser.parse(Unknown Source)
> >>         at org.apache.xerces.parsers.AbstractSAXParser.parse(Unknown 
> >> Source)
> >>         at org.apache.commons.digester.Digester.parse(Digester.java:1586)
> >>         at 
> >> org.apache.jetspeed.util.descriptor.PortletApplicationDescriptor.createPortletApplication(PortletApplicationDescriptor.java:146)

> >>
> >>         ... 9 more
> >>  INFO: Loading portlet application from web archive 
> >> C:\java\technologies\jakarta-tomcat\webapps\jetspeed\WEB-INF\deploy\jetspeed-layouts.war

> >>
> >>  INFO: Preparing to deploy portlet app "jetspeed"
> >>  INFO: jetspeed-layouts.war will be registered as a local portlet 
> >> applicaiton.
> >>  INFO: Portlet application deployment target directory is 
> >> jetspeed/jetspeed
> >>  INFO: Did not load exteneded metadata as it most likely does not 
> >> exist.  org.apache.commons.vfs.FileSystemException: Could not read 
> >> from "jar:file://C:/java/te
> >> chnologies/jakarta-tomcat/webapps/jetspeed/WEB-INF/deploy/jetspeed-layouts.war!/WEB-INF/jetspeed-portlet.xml"

> >> because it is a not a file.
> >>  INFO: Loading web.xml into memory....
> >>  INFO: Saving the portlet.xml in the registry...
> >>  INFO: Committing registry changes...
> >>  INFO: FileSystem deployment done.
> >>  INFO: Adding 
> >> jar:file://C:/java/technologies/jakarta-tomcat/webapps/jetspeed/WEB-INF/deploy/jetspeed-layouts.war!/WEB-INF/classes
> >> to class path.
> >>  INFO: Portlet app "jetspeed" successfuly deployed.
> >>  INFO: Loading portlet application from web archive 
> >> C:\java\technologies\jakarta-tomcat\webapps\jetspeed\WEB-INF\deploy\pam.war

> >>
> >>  INFO: Preparing to deploy portlet app "pam"
> >>  INFO: Deploying portlet applicaion WAR pam.war
> >>  INFO: Portlet application deployment target directory is 
> >> C:\java\technologies\jakarta-tomcat\webapps/pam
> >> Writing out infused web.xml for pam
> >>  INFO: Loading web.xml into memory....
> >>  INFO: Saving the portlet.xml in the registry...
> >>  INFO: Committing registry changes...
> >>  INFO: FileSystem deployment done.
> >>  INFO: Catalina deployment response: OK - Application installTe pour 
> >> le chemin de contexte /pam
> >>
> >>  INFO: Portlet app "pam" successfuly deployed.
> >>  INFO: Loading portlet application from web archive 
> >> C:\java\technologies\jakarta-tomcat\webapps\jetspeed\WEB-INF\deploy\security.war

> >>
> >>  INFO: Preparing to deploy portlet app "security"
> >>  INFO: Deploying portlet applicaion WAR security.war
> >>  INFO: Portlet application deployment target directory is 
> >> C:\java\technologies\jakarta-tomcat\webapps/security
> >> Writing out infused web.xml for security
> >>  INFO: Loading web.xml into memory....
> >>  INFO: Saving the portlet.xml in the registry...
> >>  INFO: Committing registry changes...
> >>  INFO: FileSystem deployment done.
> >>  INFO: Catalina deployment response: OK - Application installTe pour 
> >> le chemin de contexte /security
> >>
> >>  INFO: Portlet app "security" successfuly deployed.
> >>  INFO: Loading portlet application from web archive 
> >> C:\java\technologies\jakarta-tomcat\webapps\jetspeed\WEB-INF\deploy\struts-demo.war

> >>
> >>  INFO: Preparing to deploy portlet app "struts-demo"
> >>  INFO: Deploying portlet applicaion WAR struts-demo.war
> >>  INFO: Portlet application deployment target directory is 
> >> C:\java\technologies\jakarta-tomcat\webapps/struts-demo
> >> Writing out infused web.xml for struts-demo
> >>  INFO: Did not load exteneded metadata as it most likely does not 
> >> exist.  org.apache.commons.vfs.FileSystemException: Could not read 
> >> from "jar:file://C:/java/te
> >> chnologies/jakarta-tomcat/webapps/jetspeed/WEB-INF/deploy/struts-demo.war!/WEB-INF/jetspeed-portlet.xml"

> >> because it is a not a file.
> >>  INFO: Loading web.xml into memory....
> >>  INFO: Saving the portlet.xml in the registry...
> >>  INFO: Committing registry changes...
> >>  INFO: FileSystem deployment done.
> >>  INFO: Catalina deployment response: OK - Application installTe pour 
> >> le chemin de contexte /struts-demo
> >>
> >>  INFO: Portlet app "struts-demo" successfuly deployed.
> >>
> >> So it seems that even within the J2 webapp there is a problem with the 
> >> class loading of the preference factory. What is strange is that some 
> >> PAs deployed, but I guess they don't use any preferences ?
> >>
> >> Regards,
> >>   Serge Huber.
> >>
> >> At 16:43 21.06.2004, you wrote:
> >>
> >>> Hi Scott,
> >>>
> >>> Actually I'm calling the FileSystemPAM from my own deployer, within 
> >>> Jahia. Maybe I'm missing something in my deployment ? I have the 
> >>> jetspeed-prefs*.jar in the WEB-INF/lib directory, along with all of 
> >>> J2, and I updated the assembly script a few hours ago.
> >>>
> >>> I didn't test with auto-deploy, but I could to see if it works better.
> >>>
> >>> Regards,
> >>>   Serge...
> >>>
> >>> At 16:31 21.06.2004, you wrote:
> >>>
> >>>> Hi Serge,
> >>>>
> >>>>
> >>>> Is this exception coming from auto-deployment?  Because I am not having
> >>>> any issues with deployment.  I made PreferenceProviderImpl Startable
so
> >>>> this wouldn't happen, maybe this doesn't address all possible scenarios
> >>>> though.
> >>>>
> >>>>
> >>>> On Mon, 2004-06-21 at 10:23, Serge Huber wrote:
> >>>> > Hi,
> >>>> >
> >>>> > I'm having some problem using the FileSystemPAM from within a web
app
> >>>> > context (seems to work in the tests, which use the system class

> >>>> loader).
> >>>> >
> >>>> > Basically I get the following exception :
> >>>> >
> >>>> > java.lang.InternalError: Can't instantiate Preferences factory
> >>>> > java.lang.ClassNotFoundException:
> >>>> > org.apache.jetspeed.prefs.impl.PreferencesFactoryImpl
> >>>> >
> >>>> >          at 
> >>>> java.util.prefs.Preferences.<clinit>(Preferences.java:204)
> >>>> >          at
> >>>> > 
> >>>> org.apache.jetspeed.om.preference.impl.PrefsPreference.createPrefenceNode(PrefsPreference.java:540)

> >>>>
> >>>> >          at
> >>>> > 
> >>>> org.apache.jetspeed.om.preference.impl.PrefsPreference.<init>(PrefsPreference.java:73)

> >>>>
> >>>> >          at
> >>>> > 
> >>>> org.apache.jetspeed.util.descriptor.PortletPreferenceRule.end(PortletPreferenceRule.java:74)

> >>>>
> >>>> >          at 
> >>>> org.apache.commons.digester.Digester.endElement(Digester.java:1058)
> >>>> >          at 
> >>>> org.apache.xerces.parsers.AbstractSAXParser.endElement(Unknown
> >>>> > Source)
> >>>> >          at
> >>>> > 
> >>>> org.apache.xerces.impl.XMLDocumentFragmentScannerImpl.scanEndElement(Unknown

> >>>>
> >>>> > Source)
> >>>> >          at
> >>>> > 
> >>>> org.apache.xerces.impl.XMLDocumentFragmentScannerImpl$FragmentContentDispatcher.dispatch(Unknown

> >>>>
> >>>> > Source)
> >>>> >          at
> >>>> > 
> >>>> org.apache.xerces.impl.XMLDocumentFragmentScannerImpl.scanDocument(Unknown

> >>>>
> >>>> > Source)
> >>>> >          at 
> >>>> org.apache.xerces.parsers.XML11Configuration.parse(Unknown Source)
> >>>> >          at 
> >>>> org.apache.xerces.parsers.DTDConfiguration.parse(Unknown Source)
> >>>> >          at org.apache.xerces.parsers.XMLParser.parse(Unknown Source)
> >>>> >          at 
> >>>> org.apache.xerces.parsers.AbstractSAXParser.parse(Unknown Source)
> >>>> >          at 
> >>>> org.apache.commons.digester.Digester.parse(Digester.java:1586)
> >>>> >          at
> >>>> > 
> >>>> org.apache.jetspeed.util.descriptor.PortletApplicationDescriptor.createPortletApplication(PortletApplicationDescriptor.java:146)

> >>>>
> >>>> >          at
> >>>> > 
> >>>> org.apache.jetspeed.util.descriptor.PortletApplicationWar.createPortletApp(PortletApplicationWar.java:213)

> >>>>
> >>>> >          at
> >>>> > 
> >>>> org.apache.jetspeed.tools.pamanager.FileSystemPAM.registerApplication(FileSystemPAM.java:346)

> >>>>
> >>>> >          at
> >>>> > 
> >>>> org.apache.jetspeed.tools.pamanager.FileSystemPAM.sysDeploy(FileSystemPAM.java:297)

> >>>>
> >>>> >          at
> >>>> > 
> >>>> org.apache.jetspeed.tools.pamanager.FileSystemPAM.deploy(FileSystemPAM.java:89)

> >>>>
> >>>> >
> >>>> > I looked at the JDK's source and found the following code when

> >>>> loading the
> >>>> > PreferenceFactory implementation :
> >>>> >
> >>>> >              factory = (PreferencesFactory)
> >>>> >                 Class.forName(factoryName, false,
> >>>> > ClassLoader.getSystemClassLoader()).newInstance();
> >>>> >
> >>>> > If this means what I think it does, the preference factory may

> >>>> only be
> >>>> > loaded from the root class loader, which means that we would need

> >>>> to deploy
> >>>> > the jetspeed-prefs*.jar into Tomcat's classpath or something.
> >>>> >
> >>>> > Is this analysis correct ? If so, how to we get around this ?
> >>>> >
> >>>> > Regards,
> >>>> >    Serge Huber.
> >>>> >
> >>>> >
> >>>> >
> >>>> > - -- --- -----=[ shuber2 at jahia dot com ]=---- --- -- -
> >>>> > www.jahia.org : A collaborative source CMS and Portal Server
> >>>> >
> >>>> >
> >>>> >
> >>>> > ---------------------------------------------------------------------
> >>>> > To unsubscribe, e-mail: jetspeed-dev-unsubscribe@jakarta.apache.org
> >>>> > For additional commands, e-mail: jetspeed-dev-help@jakarta.apache.org
> >>>>
> >>>> Regards,
> >>>> -- 
> >>>> ******************************************
> >>>> *           Scott T. Weaver              *
> >>>> *         <weaver@apache.org>            *
> >>>> *     <http://www.einnovation.com>       *
> >>>> * -------------------------------------- *
> >>>> *   Apache Jetspeed Enterprise Portal    *
> >>>> *     Apache Pluto Portlet Container     *
> >>>> *                                        *
> >>>> * OpenEditPro, Website Content Mangement *
> >>>> *     <http://www.openeditpro.com>       *
> >>>> ******************************************
> >>>>
> >>>>
> >>>> ---------------------------------------------------------------------
> >>>> To unsubscribe, e-mail: jetspeed-dev-unsubscribe@jakarta.apache.org
> >>>> For additional commands, e-mail: jetspeed-dev-help@jakarta.apache.org
> >>>
> >>>
> >>> - -- --- -----=[ shuber2 at jahia dot com ]=---- --- -- -
> >>> www.jahia.org : A collaborative source CMS and Portal Server
> >>>
> >>>
> >>> ---------------------------------------------------------------------
> >>> To unsubscribe, e-mail: jetspeed-dev-unsubscribe@jakarta.apache.org
> >>> For additional commands, e-mail: jetspeed-dev-help@jakarta.apache.org
> >>
> >>
> >> - -- --- -----=[ shuber2 at jahia dot com ]=---- --- -- -
> >> www.jahia.org : A collaborative source CMS and Portal Server
> >>
> >>
> >> ---------------------------------------------------------------------
> >> To unsubscribe, e-mail: jetspeed-dev-unsubscribe@jakarta.apache.org
> >> For additional commands, e-mail: jetspeed-dev-help@jakarta.apache.org
> > 
> > 
> > - -- --- -----=[ shuber2 at jahia dot com ]=---- --- -- -
> > www.jahia.org : A collaborative source CMS and Portal Server
> > 
> > 
> > ---------------------------------------------------------------------
> > To unsubscribe, e-mail: jetspeed-dev-unsubscribe@jakarta.apache.org
> > For additional commands, e-mail: jetspeed-dev-help@jakarta.apache.org
> > 
> > 
> > 
> > 
> 
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: jetspeed-dev-unsubscribe@jakarta.apache.org
> For additional commands, e-mail: jetspeed-dev-help@jakarta.apache.org
-- 
******************************************
*           Scott T. Weaver              *
*         <weaver@apache.org>            *
*     <http://www.einnovation.com>       *   
* -------------------------------------- *
*   Apache Jetspeed Enterprise Portal    *
*     Apache Pluto Portlet Container     *
*                                        *
* OpenEditPro, Website Content Mangement *
*     <http://www.openeditpro.com>       *
******************************************


---------------------------------------------------------------------
To unsubscribe, e-mail: jetspeed-dev-unsubscribe@jakarta.apache.org
For additional commands, e-mail: jetspeed-dev-help@jakarta.apache.org


Mime
View raw message