Birt Chart Script Error [message #755894] |
Thu, 10 November 2011 00:28  |
Eclipse User |
|
|
|
I am trying a test deployment of report using charts with BIRT and I am getting a NullPointerException from a class(SetChartPalette.class) in the BIRT functions library(birt.functions.lib_2.5.2.1.jar). The tables etc in the report work fine. Google does not bring up any related discussions so any help is appreciated since I am at a standstill. Thanks!
The details are as follows:
OS : Ubuntu 10.4 64-bit
Eclipse: Helios (Build id: 20100917-0705)
Tomcat: 6.0.29
BIRT: 2.6.1
Browsers: Firefox 3.6.13 & Chromium 8.0.552.224
The exception:
-
null ( 1 time(s) )
detail : org.eclipse.birt.report.engine.api.EngineException
at org.eclipse.birt.report.engine.executor.ExecutionContext.addException(ExecutionContext.java:1195)
at org.eclipse.birt.report.engine.presentation.LocalizedContentVisitor.processExtendedContent(LocalizedContentVisitor.java:1046)
at org.eclipse.birt.report.engine.presentation.LocalizedContentVisitor.localizeForeign(LocalizedContentVisitor.java:579)
at org.eclipse.birt.report.engine.presentation.LocalizedContentVisitor.localize(LocalizedContentVisitor.java:163)
at org.eclipse.birt.report.engine.internal.executor.l18n.LocalizedReportItemExecutor.execute(LocalizedReportItemExecutor.java:37)
at org.eclipse.birt.report.engine.layout.html.HTMLBlockStackingLM.layoutNodes(HTMLBlockStackingLM.java:65)
at org.eclipse.birt.report.engine.layout.html.HTMLStackingLM.layoutChildren(HTMLStackingLM.java:26)
at org.eclipse.birt.report.engine.layout.html.HTMLAbstractLM.layout(HTMLAbstractLM.java:140)
at org.eclipse.birt.report.engine.layout.html.HTMLInlineStackingLM.resumeLayout(HTMLInlineStackingLM.java:111)
at org.eclipse.birt.report.engine.layout.html.HTMLInlineStackingLM.layoutNodes(HTMLInlineStackingLM.java:160)
at org.eclipse.birt.report.engine.layout.html.HTMLStackingLM.layoutChildren(HTMLStackingLM.java:26)
at org.eclipse.birt.report.engine.layout.html.HTMLAbstractLM.layout(HTMLAbstractLM.java:140)
at org.eclipse.birt.report.engine.layout.html.HTMLBlockStackingLM.layoutNodes(HTMLBlockStackingLM.java:70)
at org.eclipse.birt.report.engine.layout.html.HTMLStackingLM.layoutChildren(HTMLStackingLM.java:26)
at org.eclipse.birt.report.engine.layout.html.HTMLTableLM.layoutChildren(HTMLTableLM.java:132)
at org.eclipse.birt.report.engine.layout.html.HTMLAbstractLM.layout(HTMLAbstractLM.java:140)
at org.eclipse.birt.report.engine.layout.html.HTMLBlockStackingLM.layoutNodes(HTMLBlockStackingLM.java:70)
at org.eclipse.birt.report.engine.layout.html.HTMLPageLM.layout(HTMLPageLM.java:90)
at org.eclipse.birt.report.engine.layout.html.HTMLReportLayoutEngine.layout(HTMLReportLayoutEngine.java:99)
at org.eclipse.birt.report.engine.api.impl.RenderTask$PageRangeRender.render(RenderTask.java:662)
at org.eclipse.birt.report.engine.api.impl.RenderTask.render(RenderTask.java:284)
at org.eclipse.birt.report.service.ReportEngineService.renderReport(ReportEngineService.java:1537)
at org.eclipse.birt.report.service.BirtViewerReportService.getPage(BirtViewerReportService.java:204)
at org.eclipse.birt.report.service.actionhandler.BirtChangeParameterActionHandler.doRenderPage(BirtChangeParameterActionHandler.java:82)
at org.eclipse.birt.report.service.actionhandler.AbstractChangeParameterActionHandler.__execute(AbstractChangeParameterActionHandler.java:103)
at org.eclipse.birt.report.service.actionhandler.AbstractBaseActionHandler.execute(AbstractBaseActionHandler.java:90)
at org.eclipse.birt.report.soapengine.processor.AbstractBaseDocumentProcessor.__executeAction(AbstractBaseDocumentProcessor.java:47)
at org.eclipse.birt.report.soapengine.processor.AbstractBaseComponentProcessor.executeAction(AbstractBaseComponentProcessor.java:143)
at org.eclipse.birt.report.soapengine.processor.BirtDocumentProcessor.handleChangeParameter(BirtDocumentProcessor.java:100)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:597)
at org.eclipse.birt.report.soapengine.processor.AbstractBaseComponentProcessor.process(AbstractBaseComponentProcessor.java:112)
at org.eclipse.birt.report.soapengine.endpoint.BirtSoapBindingImpl.getUpdatedObjects(BirtSoapBindingImpl.java:66)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:597)
at org.apache.axis.providers.java.RPCProvider.invokeMethod(RPCProvider.java:397)
at org.apache.axis.providers.java.RPCProvider.processMessage(RPCProvider.java:186)
at org.apache.axis.providers.java.JavaProvider.invoke(JavaProvider.java:323)
at org.apache.axis.strategies.InvocationStrategy.visit(InvocationStrategy.java:32)
at org.apache.axis.SimpleChain.doVisiting(SimpleChain.java:118)
at org.apache.axis.SimpleChain.invoke(SimpleChain.java:83)
at org.apache.axis.handlers.soap.SOAPService.invoke(SOAPService.java:454)
at org.apache.axis.server.AxisServer.invoke(AxisServer.java:281)
at org.apache.axis.transport.http.AxisServlet.doPost(AxisServlet.java:699)
at org.eclipse.birt.report.servlet.BirtSoapMessageDispatcherServlet.doPost(BirtSoapMessageDispatcherServlet.java:265)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:637)
at org.apache.axis.transport.http.AxisServletBase.service(AxisServletBase.java:327)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:717)
at org.eclipse.birt.report.servlet.BirtSoapMessageDispatcherServlet.service(BirtSoapMessageDispatcherServlet.java:122)
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:290)
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
at org.eclipse.birt.report.filter.ViewerFilter.doFilter(ViewerFilter.java:68)
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235)
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:233)
at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:191)
at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:127)
at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:102)
at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:109)
at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:298)
at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:857)
at org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.process(Http11Protocol.java:588)
at org.apache.tomcat.util.net.JIoEndpoint$Worker.run(JIoEndpoint.java:489)
at java.lang.Thread.run(Thread.java:662)
Caused by: org.eclipse.birt.chart.exception.ChartException
at org.eclipse.birt.chart.factory.Generator.render(Generator.java:1306)
at org.eclipse.birt.chart.reportitem.ChartReportItemPresentationBase.renderToImageFile(ChartReportItemPresentationBase.java:1010)
at org.eclipse.birt.chart.reportitem.ChartReportItemPresentationBase.generateRenderObject(ChartReportItemPresentationBase.java:861)
at org.eclipse.birt.chart.reportitem.ChartReportItemPresentationBase.onRowSets(ChartReportItemPresentationBase.java:819)
at org.eclipse.birt.chart.reportitem.ChartReportItemPresentationProxy.onRowSets(ChartReportItemPresentationProxy.java:108)
at org.eclipse.birt.report.engine.presentation.LocalizedContentVisitor.processExtendedContent(LocalizedContentVisitor.java:1023)
... 66 more
Caused by: java.lang.NullPointerException
at innovent.birt.functions.SetChartPalette.setSeriesFont(SetChartPalette.java:106)
at innovent.birt.functions.SetChartPalette.execute(SetChartPalette.java:97)
at org.eclipse.birt.core.script.functionservice.impl.ScriptFunction.execute(ScriptFunction.java:146)
at org.eclipse.birt.core.script.functionservice.impl.CategoryWrapper$1.call(CategoryWrapper.java:67)
at org.mozilla.javascript.optimizer.OptRuntime.call2(OptRuntime.java:76)
at org.mozilla.javascript.gen.c37._c1(/report/body/grid[@id="8"]/row[@id="12"]/cell[@id="576"]/extended-item[@id="574"]/method[@name="onRender"]:15)
at org.mozilla.javascript.gen.c37.call(/report/body/grid[@id="8"]/row[@id="12"]/cell[@id="576"]/extended-item[@id="574"]/method[@name="onRender"])
at org.mozilla.javascript.ContextFactory.doTopCall(ContextFactory.java:398)
at org.mozilla.javascript.ScriptRuntime.doTopCall(ScriptRuntime.java:3065)
at org.mozilla.javascript.gen.c37.call(/report/body/grid[@id="8"]/row[@id="12"]/cell[@id="576"]/extended-item[@id="574"]/method[@name="onRender"])
at org.eclipse.birt.chart.script.AbstractScriptHandler.callJavascriptFunction(AbstractScriptHandler.java:370)
at org.eclipse.birt.chart.script.AbstractScriptHandler.callFunction(AbstractScriptHandler.java:558)
at org.eclipse.birt.chart.render.AxesRenderer.renderPlot(AxesRenderer.java:2256)
at org.eclipse.birt.chart.render.AxesRenderer.render(AxesRenderer.java:313)
at org.eclipse.birt.chart.factory.Generator.render(Generator.java:1301)
... 71 more
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
Re: Birt Chart Script Error [message #775841 is a reply to message #775816] |
Fri, 06 January 2012 14:07   |
Eclipse User |
|
|
|
Shane,
This does appear to be a bug. Any chance you could open a bugzilla
entry with your sample? As a work around why not directly attach the
chart to the dataset and then use the category expression:
if (BirtComp.like(row["PRODUCTCODE"],"%1678")) "Group1"
else if (BirtComp.like(row["PRODUCTCODE"],"%1949")) "Group2"
else if (BirtComp.like(row["PRODUCTCODE"],"%2016")) "Group3"
else if (BirtComp.like(row["PRODUCTCODE"],"%4698")) "Group4"
else if (BirtComp.like(row["PRODUCTCODE"],"%4757")) "Group5"
else "Group6";
I modified the example to do this and it is attached. I also added a
binding to the table to get the group name. I use this in the group
instead of the expression.
Jason
On 1/6/2012 1:18 PM, Shane Dodge wrote:
> Thanks again for your help on this.
>
> The good news (for me) is that I am able to repro the issue with the sample data and the report is attached. Please look at the ProductCodeGroup I created. The group uses the following if (BirtComp.like(row["PRODUCTCODE"],"%1678")) "Group1"
> else if (BirtComp.like(row["PRODUCTCODE"],"%1949")) "Group2"
> etc
>
> It seems like this is where the chart has issues. Once I try to add that grouping to the chart I get the Null Pointer Exception.
>
> I am not sure I have much in the way of options to work around this type of grouping because of the way my dataset is created. I have a huge concatenated string that I need to group by the a word that exists in the middle of that string.
>
> Shane
|
|
|
|
Re: Birt Chart Script Error [message #1758198 is a reply to message #775834] |
Fri, 24 March 2017 11:13  |
Eclipse User |
|
|
|
Hi Jason,
This does appear to be a bug.
IS there any solution found for this Bug now, its been there.
I am also facing the same issue i.e.
Null pointer exception when i use Inherit from Columns and Groups from for the Graph.
Help please.
Thanks
Yoovraj
|
|
|
Powered by
FUDForum. Page generated in 0.06045 seconds