Home
Designing Analytics Reports
Using non serializable objects in pojo data set
Migrateduser
<p>In all of my reports I use IPojoDataSet implementations that return arbitrary java objects. None of those objects implement Serializable interface. So far I had no problems with such approach. Things changed after I switched from viewing my reports with <em>run</em> servlet to <em>frameset</em>. Now I would always get an exception similar to this one:</p>
<p><span style="font-size:12px;">org.eclipse.birt.report.engine.api.EngineException: Class my.test.Calendar is not supported to be serialized.<br>
at org.eclipse.birt.report.engine.executor.ExecutionContext.addException(ExecutionContext.java:1245)<br>
at org.eclipse.birt.report.engine.executor.ExecutionContext.addException(ExecutionContext.java:1224)<br>
at org.eclipse.birt.report.engine.executor.QueryItemExecutor.executeQuery(QueryItemExecutor.java:96)<br>
at org.eclipse.birt.report.engine.executor.TableItemExecutor.execute(TableItemExecutor.java:62)<br>
at org.eclipse.birt.report.engine.internal.executor.wrap.WrappedReportItemExecutor.execute(WrappedReportItemExecutor.java:46)<br>
at org.eclipse.birt.report.engine.internal.executor.emitter.ReportItemEmitterExecutor.execute(ReportItemEmitterExecutor.java:46)<br>
at org.eclipse.birt.report.engine.internal.executor.dup.SuppressDuplicateItemExecutor.execute(SuppressDuplicateItemExecutor.java:43)<br>
at org.eclipse.birt.report.engine.layout.html.HTMLBlockStackingLM.layoutNodes(HTMLBlockStackingLM.java:65)<br>
at org.eclipse.birt.report.engine.layout.html.HTMLStackingLM.layoutChildren(HTMLStackingLM.java:26)</span></p>
<p> </p>
<p>I guess it has something to do with the separation of Run and Render tasks in frameset.</p>
<p>So the question is if it's by specification that all objects returned by IPojoDataSet should implement Serializable? If not, is there any way to configure birt runtime not to try to serialize dataset results?</p>
<p> </p>
<p>I am using birt in version 4.5.0</p>
Find more posts tagged with
Comments
There are no comments yet