cocoon-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Stefano Mazzocchi <stef...@apache.org>
Subject Re: [BUG] very weird NPE in JXTemplateTransformer
Date Tue, 29 Apr 2003 13:30:34 GMT
on 4/29/03 6:03 AM Pier Fumagalli wrote:

> "Stefano Mazzocchi" <stefano@apache.org> wrote:
> 
> 
>>This is a pretty weird bug. I've updated linotype to the latest and
>>greatest CVS but I get a NPE on this pipeline:
>>
>>  <map:match pattern="edit/news/*/">
>>   <map:generate src="cocoon://news/{1}.xml"/>
>>   <map:transform src="stylesheets/news2edit.xslt">
>>    <map:parameter name="home" value="{global:home}"/>
>>   </map:transform>
>>   <map:transform type="jx"/>
>>   <map:serialize/>
>>  </map:match>
> 
> 
> I've noticed a similar one in the JX Generator... Any stacktrace from your
> end?

java.lang.RuntimeException: java.lang.NullPointerException
	at
org.apache.xalan.transformer.TransformerImpl.run(TransformerImpl.java:3363)
	at
org.apache.xalan.transformer.TransformerHandlerImpl.endDocument(TransformerHandlerImpl.java:427)
	at
org.apache.cocoon.xml.AbstractXMLPipe.endDocument(AbstractXMLPipe.java:91)
	at
org.apache.cocoon.transformation.TraxTransformer.endDocument(TraxTransformer.java:503)
	at
org.apache.cocoon.generation.JXTemplateGenerator.execute(JXTemplateGenerator.java:2133)
	at
org.apache.cocoon.generation.JXTemplateGenerator.access$600(JXTemplateGenerator.java:247)
	at
org.apache.cocoon.generation.JXTemplateGenerator$TransformerAdapter$TemplateConsumer.endDocument(JXTemplateGenerator.java:1844)
	at
org.apache.cocoon.xml.AbstractXMLPipe.endDocument(AbstractXMLPipe.java:91)
	at
org.apache.cocoon.components.source.impl.EnvironmentChanger.endDocument(SitemapSource.java:524)
	at
org.apache.cocoon.components.sax.XMLTeePipe.endDocument(XMLTeePipe.java:102)
	at
org.apache.cocoon.components.sax.XMLByteStreamInterpreter.parse(XMLByteStreamInterpreter.java:119)
	at
org.apache.cocoon.components.sax.XMLByteStreamInterpreter.deserialize(XMLByteStreamInterpreter.java:109)
	at
org.apache.cocoon.components.pipeline.impl.AbstractCachingProcessingPipeline.processXMLPipeline(AbstractCachingProcessingPipeline.java:251)
	at
org.apache.cocoon.components.pipeline.AbstractProcessingPipeline.process(AbstractProcessingPipeline.java:681)
	at
org.apache.cocoon.components.source.impl.SitemapSource.toSAX(SitemapSource.java:414)
	at
org.apache.cocoon.environment.AbstractEnvironment.toSAX(AbstractEnvironment.java:538)
	at
org.apache.cocoon.environment.http.HttpEnvironment.toSAX(HttpEnvironment.java:305)
	at
org.apache.cocoon.environment.AbstractEnvironment.toSAX(AbstractEnvironment.java:521)
	at
org.apache.cocoon.environment.wrapper.EnvironmentWrapper.toSAX(EnvironmentWrapper.java:350)
	at
org.apache.cocoon.generation.FileGenerator.generate(FileGenerator.java:140)
	at
org.apache.cocoon.components.pipeline.AbstractProcessingPipeline.processXMLPipeline(AbstractProcessingPipeline.java:545)
	at
org.apache.cocoon.components.pipeline.impl.AbstractCachingProcessingPipeline.processXMLPipeline(AbstractCachingProcessingPipeline.java:214)
	at
org.apache.cocoon.components.pipeline.AbstractProcessingPipeline.process(AbstractProcessingPipeline.java:489)
	at
org.apache.cocoon.components.treeprocessor.sitemap.SerializeNode.invoke(SerializeNode.java:150)
	at
org.apache.cocoon.components.treeprocessor.AbstractParentProcessingNode.invokeNodes(AbstractParentProcessingNode.java:84)
	at
org.apache.cocoon.components.treeprocessor.sitemap.PreparableMatchNode.invoke(PreparableMatchNode.java:164)
	at
org.apache.cocoon.components.treeprocessor.AbstractParentProcessingNode.invokeNodes(AbstractParentProcessingNode.java:108)
	at
org.apache.cocoon.components.treeprocessor.sitemap.PipelineNode.invoke(PipelineNode.java:162)
	at
org.apache.cocoon.components.treeprocessor.AbstractParentProcessingNode.invokeNodes(AbstractParentProcessingNode.java:108)
	at
org.apache.cocoon.components.treeprocessor.sitemap.PipelinesNode.invoke(PipelinesNode.java:162)
	at
org.apache.cocoon.components.treeprocessor.TreeProcessor.process(TreeProcessor.java:325)
	at
org.apache.cocoon.components.treeprocessor.TreeProcessor.process(TreeProcessor.java:307)
	at
org.apache.cocoon.environment.ForwardRedirector.cocoonRedirect(ForwardRedirector.java:207)
	at
org.apache.cocoon.environment.ForwardRedirector.redirect(ForwardRedirector.java:114)
	at
org.apache.cocoon.components.flow.AbstractInterpreter.forwardTo(AbstractInterpreter.java:227)
	at
org.apache.cocoon.components.flow.javascript.JSCocoon.jsFunction_forwardTo(JSCocoon.java:227)
	at inv2.invoke()
	at org.mozilla.javascript.FunctionObject.doInvoke(FunctionObject.java:523)
	at org.mozilla.javascript.FunctionObject.call(FunctionObject.java:438)
	at org.mozilla.javascript.ScriptRuntime.call(ScriptRuntime.java:1244)
	at
org.mozilla.javascript.continuations.ContinuationInterpreter.interpret(ContinuationInterpreter.java:1087)
	at
org.mozilla.javascript.continuations.ContinuationInterpreter.interpret(ContinuationInterpreter.java:173)
	at
org.mozilla.javascript.continuations.ContinuationInterpreter.interpret(ContinuationInterpreter.java:121)
	at
org.mozilla.javascript.continuations.InterpretedFunctionImpl.call(InterpretedFunctionImpl.java:121)
	at org.mozilla.javascript.ScriptRuntime.call(ScriptRuntime.java:1244)
	at
org.apache.cocoon.components.flow.javascript.JavaScriptInterpreter.callFunction(JavaScriptInterpreter.java:580)
	at
org.apache.cocoon.components.treeprocessor.sitemap.CallFunctionNode.invoke(CallFunctionNode.java:196)
	at
org.apache.cocoon.components.treeprocessor.AbstractParentProcessingNode.invokeNodes(AbstractParentProcessingNode.java:84)

	at
org.apache.cocoon.components.treeprocessor.sitemap.PreparableMatchNode.invoke(PreparableMatchNode.java:164)
	at
org.apache.cocoon.components.treeprocessor.AbstractParentProcessingNode.invokeNodes(AbstractParentProcessingNode.java:108)
	at
org.apache.cocoon.components.treeprocessor.sitemap.PipelineNode.invoke(PipelineNode.java:162)
	at
org.apache.cocoon.components.treeprocessor.AbstractParentProcessingNode.invokeNodes(AbstractParentProcessingNode.java:108)
	at
org.apache.cocoon.components.treeprocessor.sitemap.PipelinesNode.invoke(PipelinesNode.java:162)
	at
org.apache.cocoon.components.treeprocessor.TreeProcessor.process(TreeProcessor.java:325)
	at
org.apache.cocoon.components.treeprocessor.TreeProcessor.process(TreeProcessor.java:307)
	at org.apache.cocoon.Cocoon.process(Cocoon.java:640)
	at org.apache.cocoon.servlet.CocoonServlet.service(CocoonServlet.java:1139)
	at javax.servlet.http.HttpServlet.service(HttpServlet.java:853)
	at org.mortbay.jetty.servlet.ServletHolder.handle(ServletHolder.java:360)
	at
org.mortbay.jetty.servlet.WebApplicationHandler.dispatch(WebApplicationHandler.java:294)
	at org.mortbay.jetty.servlet.ServletHandler.handle(ServletHandler.java:558)
	at org.mortbay.http.HttpContext.handle(HttpContext.java:1714)
	at
org.mortbay.jetty.servlet.WebApplicationContext.handle(WebApplicationContext.java:507)
	at org.mortbay.http.HttpContext.handle(HttpContext.java:1664)
	at org.mortbay.http.HttpServer.service(HttpServer.java:863)
	at org.mortbay.http.HttpConnection.service(HttpConnection.java:775)
	at org.mortbay.http.HttpConnection.handleNext(HttpConnection.java:939)
	at org.mortbay.http.HttpConnection.handle(HttpConnection.java:792)
	at
org.mortbay.http.SocketListener.handleConnection(SocketListener.java:201)
	at org.mortbay.util.ThreadedServer.handle(ThreadedServer.java:289)
	at org.mortbay.util.ThreadPool$PoolThread.run(ThreadPool.java:455)


I believe the JXTemplate* sends some null stuff into the SAX events
instead of "" in some places.

Chris, did you experience anything like this before?

-- 
Stefano.



Mime
View raw message