pivot4j icon indicating copy to clipboard operation
pivot4j copied to clipboard

PDF export no longer works in Pentaho platform.

Open mysticfall opened this issue 10 years ago • 5 comments

It seems Pentaho platform bundles its own version of FOP, and throws following exception when PDF export is requested :

Caused by: java.lang.ClassCastException: org.apache.fop.render.pdf.PDFRendererMaker cannot be cast to org.apache.fop.render.AbstractRendererMaker
        at org.apache.fop.render.RendererFactory.discoverRenderers(RendererFactory.java:425)
        at org.apache.fop.render.RendererFactory.<init>(RendererFactory.java:61)
        at org.apache.fop.apps.FopFactory.<init>(FopFactory.java:179)
        at org.apache.fop.apps.FopFactory.newInstance(FopFactory.java:190)
        at org.pivot4j.ui.fop.FopExporter.createFopFactory(FopExporter.java:271)
        at org.pivot4j.ui.fop.FopExporter.startRender(FopExporter.java:320)
        at org.pivot4j.ui.fop.FopExporter.startRender(FopExporter.java:40)
        at org.pivot4j.ui.table.TableRenderer.render(TableRenderer.java:439)
        at org.pivot4j.analytics.ui.PivotExportHandler.exportPdf(PivotExportHandler.java:406)
        at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
        at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)
        at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
        at java.lang.reflect.Method.invoke(Method.java:601)
        at org.apache.el.parser.AstValue.invoke(AstValue.java:191) 
  • Related forum post : https://groups.google.com/d/msg/pivot4j-list/rVCXdmrmwxE/1Jke8mwBqz4J

mysticfall avatar Mar 09 '14 13:03 mysticfall

Upon some tests, found the root cause of the problem. Even though IPluginClassLoader implementation of Pentaho platform supports overriding class loading order, classes packaged in an older version of FOP library from the platform are still loaded via service provider mechanism.

It seems we'll have to downgrade FOP to 0.9.x as a workaround for now.

mysticfall avatar Mar 09 '14 14:03 mysticfall

Unfortunately, I found that downgrading to 0.9.x is not viable as that version has serious bug with multi-page table.

  • https://issues.apache.org/bugzilla/show_bug.cgi?id=45079

There's nothing we can do till Pentaho decides either to remove or upgrade its own version of FOP library.

mysticfall avatar Mar 26 '14 09:03 mysticfall

Posted an upstream issue report here :

  • http://jira.pentaho.com/browse/BISERVER-11224

mysticfall avatar Mar 26 '14 09:03 mysticfall

It seems that the bug is fixed with Pentaho BI 5.1.0. We'll close this issue once that version is released and tested.

mysticfall avatar Apr 27 '14 05:04 mysticfall

What about "when exporting to pdf had problems with Russian encoding - instead of Russian letters were ###" ? This issue is not fixed yet (

mzko avatar Mar 15 '17 12:03 mzko