Re: XSLT import/include errors

gelo1234 <[email protected]>
Newsgroups gmane.text.xml.cocoon.user
Message-ID <CAPJaKUrVWE4-4C1Ni=P6t4_tTp4fZBX1v86u9d4eL+UdySxs5w@mail.gmail.com>
Now Im lost. The Cocoon context doesn't work anymore. Restarting Tomcat
doesn't help. I tried to clean work directory, and still
NullPointerException.

Any idea what might be wrong ?
And how to switch off imported xslt caching ?

INFO: Starting Servlet Engine: Apache Tomcat/7.0.40
cze 20, 2013 8:43:28 PM org.apache.catalina.startup.HostConfig
deployDirectory
INFO: Deploying web application directory
/var/lib/tomcat/webapps/mywebapp-1.0-SNAPSHOT
cze 20, 2013 8:43:29 PM org.apache.catalina.core.ContainerBase
addChildInternal
SEVERE: ContainerBase.addChild: start:
org.apache.catalina.LifecycleException: Failed to start component
[StandardEngine[Catalina].StandardHost[localhost].StandardContext[/mywebapp-1.0-SNAPSHOT]]
    at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:154)
    at
org.apache.catalina.core.ContainerBase.addChildInternal(ContainerBase.java:901)
    at
org.apache.catalina.core.ContainerBase.addChild(ContainerBase.java:877)
    at org.apache.catalina.core.StandardHost.addChild(StandardHost.java:633)
    at
org.apache.catalina.startup.HostConfig.deployDirectory(HostConfig.java:1114)
    at
org.apache.catalina.startup.HostConfig$DeployDirectory.run(HostConfig.java:1672)
    at java.util.concurrent.Executors$RunnableAdapter.call(Unknown Source)
    at java.util.concurrent.FutureTask$Sync.innerRun(Unknown Source)
    at java.util.concurrent.FutureTask.run(Unknown Source)
    at java.util.concurrent.ThreadPoolExecutor.runWorker(Unknown Source)
    at java.util.concurrent.ThreadPoolExecutor$Worker.run(Unknown Source)
    at java.lang.Thread.run(Unknown Source)
Caused by: java.lang.NullPointerException
    at
org.apache.catalina.startup.ContextConfig.processAnnotationsFile(ContextConfig.java:2092)
    at
org.apache.catalina.startup.ContextConfig.processAnnotationsFile(ContextConfig.java:2093)
    at
org.apache.catalina.startup.ContextConfig.processAnnotationsFile(ContextConfig.java:2093)
    at
org.apache.catalina.startup.ContextConfig.processAnnotationsFile(ContextConfig.java:2093)
    at
org.apache.catalina.startup.ContextConfig.processAnnotationsFile(ContextConfig.java:2093)
    at
org.apache.catalina.startup.ContextConfig.webConfig(ContextConfig.java:1300)
    at
org.apache.catalina.startup.ContextConfig.configureStart(ContextConfig.java:878)
    at
org.apache.catalina.startup.ContextConfig.lifecycleEvent(ContextConfig.java:369)
    at
org.apache.catalina.util.LifecycleSupport.fireLifecycleEvent(LifecycleSupport.java:119)
    at
org.apache.catalina.util.LifecycleBase.fireLifecycleEvent(LifecycleBase.java:90)
    at
org.apache.catalina.core.StandardContext.startInternal(StandardContext.java:5269)
    at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:150)
    ... 11 more

cze 20, 2013 8:43:29 PM org.apache.catalina.startup.HostConfig
deployDirectory
SEVERE: Error deploying web application directory
/var/lib/tomcat/webapps/mywebapp-1.0-SNAPSHOT
java.lang.IllegalStateException: ContainerBase.addChild: start:
org.apache.catalina.LifecycleException: Failed to start component
[StandardEngine[Catalina].StandardHost[localhost].StandardContext[/mywebapp-1.0-SNAPSHOT]]
    at
org.apache.catalina.core.ContainerBase.addChildInternal(ContainerBase.java:904)
    at
org.apache.catalina.core.ContainerBase.addChild(ContainerBase.java:877)
    at org.apache.catalina.core.StandardHost.addChild(StandardHost.java:633)
    at
org.apache.catalina.startup.HostConfig.deployDirectory(HostConfig.java:1114)
    at
org.apache.catalina.startup.HostConfig$DeployDirectory.run(HostConfig.java:1672)
    at java.util.concurrent.Executors$RunnableAdapter.call(Unknown Source)
    at java.util.concurrent.FutureTask$Sync.innerRun(Unknown Source)
    at java.util.concurrent.FutureTask.run(Unknown Source)
    at java.util.concurrent.ThreadPoolExecutor.runWorker(Unknown Source)
    at java.util.concurrent.ThreadPoolExecutor$Worker.run(Unknown Source)
    at java.lang.Thread.run(Unknown Source)

Greetings,
Greg



2013/6/20 Javier Puerto <[email protected]>

> Hi Greg,
>
> El 20/06/2013 20:00, "gelo1234" <[email protected]> escribió:
>
> >
> >
> > It looks like XSLT also got cut in functionality in C3. I tried to rerun
> old XSL stylesheets with new C3 and gave up.
> >
> > The error says nothing meaningful:
> >
> > <exception-report class="org.apache.cocoon.pipeline.SetupException"
> timestamp="Thu, 20 Jun 2013 19:58:23 +0200"><message>Impossible to read
> XSLT from 'javax.xml.transform.stream.StreamSource@cba24d', see nested
> exception</message><cause>Could not compile
> stylesheet</cause><stacktraceCause>javax.xml.transform.TransformerConfigurationException:
> Could not compile stylesheet
> >     at
> com.sun.org.apache.xalan.internal.xsltc.trax.TransformerFactoryImpl.newTemplates(Unknown
> Source)
> >     at
> org.apache.cocoon.sax.component.XSLTTransformer.load(XSLTTransformer.java:216)
> >     at
> org.apache.cocoon.sax.component.XSLTTransformer.load(XSLTTransformer.java:165)
> >     at
> org.apache.cocoon.sax.component.XSLTTransformer.setConfiguration(XSLTTransformer.java:264)
> >     at
> org.apache.cocoon.sitemap.InvocationImpl.installComponent(InvocationImpl.java:257)
> >     at
> >
> > It looks like there is a problem with xsl:import/xsl:include from the
> main xsl stylesheet.
>
> You are right, seems to be a problem with the imports. I've used Imports
> and includes with cocoo3 without problems, except that imported files are
> cached and doesn't update running in RCL. The xslt engine is still xalan so
> the templates should work like before except for the sources with cocoon:/
> protocol that aren't supported.
>
> > Moreover I found that when <xsl:template match="RootElement" is not in
> the main XSL stylesheet the same error appears.
>
> Could you send an example block to reproduce the issue?
>
> >
> > Can we switch on more debugging info what is wrong ?
>
> You can edit the logback.xml file and set level to debug but the exception
> comes from xalan. I suggest to look for sources loaded with cocoon:/ in
> your code and substitute by servlet:/.
>
> >
> > Greetings,
> > Greg
>
> Salu2.
>
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.