Project

General

Profile

Defect #845

Barcode4J

Added by Lambert Willemsen over 9 years ago. Updated about 7 years ago.

Status:
New
Priority:
Urgent
Assignee:
-
Start date:
03/13/2015
Due date:
% Done:

0%

Estimated time:
Browser (if web client):

Description

Servoy version 6.1.6 / Plugin version 4.0.2

When using a code39 barcode in a report the following exception is throwed when printing the report (output-format = print) :
With output-format = pdf : no problem !

Exception in thread "AWT-EventQueue-2" java.lang.NoSuchMethodError: org.apache.batik.dom.AbstractDOMImplementation.registerFeature(Ljava/lang/String;Ljava/lang/Object;)V
at org.apache.batik.dom.svg.SVGDOMImplementation.<init>(SVGDOMImplementation.java:93)
at org.apache.batik.dom.svg.SVGDOMImplementation.<clinit>(SVGDOMImplementation.java:1596)
at org.apache.batik.dom.svg.SAXSVGDocumentFactory.<init>(SAXSVGDocumentFactory.java:120)
at net.sf.jasperreports.renderers.BatikRenderer.ensureSvg(BatikRenderer.java:200)
at net.sf.jasperreports.renderers.BatikRenderer.ensureSvg(BatikRenderer.java:234)
at net.sf.jasperreports.renderers.BatikRenderer.getDimension(BatikRenderer.java:152)
at net.sf.jasperreports.engine.export.draw.ImageDrawer.draw(ImageDrawer.java:130)
at net.sf.jasperreports.engine.export.draw.PrintDrawVisitor.visit(PrintDrawVisitor.java:133)
at net.sf.jasperreports.engine.export.draw.PrintDrawVisitor.visit(PrintDrawVisitor.java:57)
at net.sf.jasperreports.engine.fill.JRTemplatePrintImage.accept(JRTemplatePrintImage.java:442)
at net.sf.jasperreports.engine.export.draw.FrameDrawer.draw(FrameDrawer.java:251)
at net.sf.jasperreports.engine.export.draw.FrameDrawer.draw(FrameDrawer.java:173)
at net.sf.jasperreports.engine.export.draw.PrintDrawVisitor.visit(PrintDrawVisitor.java:180)
at net.sf.jasperreports.engine.export.draw.PrintDrawVisitor.visit(PrintDrawVisitor.java:57)
at net.sf.jasperreports.engine.fill.JRTemplatePrintFrame.accept(JRTemplatePrintFrame.java:111)
at net.sf.jasperreports.engine.export.draw.FrameDrawer.draw(FrameDrawer.java:251)
at net.sf.jasperreports.engine.export.draw.FrameDrawer.draw(FrameDrawer.java:199)
at net.sf.jasperreports.engine.export.JRGraphics2DExporter.exportPage(JRGraphics2DExporter.java:272)
at net.sf.jasperreports.engine.export.JRGraphics2DExporter.exportReportToGraphics2D(JRGraphics2DExporter.java:245)
at net.sf.jasperreports.engine.export.JRGraphics2DExporter.exportReport(JRGraphics2DExporter.java:184)
at net.sf.jasperreports.view.JRViewer.paintPage(JRViewer.java:2131)
at net.sf.jasperreports.view.JRViewer$PageRenderer.paintComponent(JRViewer.java:2281)
at javax.swing.JComponent.paint(Unknown Source)
at javax.swing.JComponent.paintChildren(Unknown Source)
at javax.swing.JComponent.paint(Unknown Source)
at javax.swing.JComponent.paintChildren(Unknown Source)
at javax.swing.JComponent.paint(Unknown Source)
at javax.swing.JComponent.paintChildren(Unknown Source)
at javax.swing.JComponent.paint(Unknown Source)
at javax.swing.JComponent.paintChildren(Unknown Source)
at javax.swing.JComponent.paint(Unknown Source)
at javax.swing.JViewport.paint(Unknown Source)
at javax.swing.JComponent.paintChildren(Unknown Source)
at javax.swing.JComponent.paint(Unknown Source)
at javax.swing.JComponent.paintChildren(Unknown Source)
at javax.swing.JComponent.paint(Unknown Source)
at javax.swing.JComponent.paintChildren(Unknown Source)
at javax.swing.JComponent.paint(Unknown Source)
at javax.swing.JComponent.paintChildren(Unknown Source)
at javax.swing.JComponent.paint(Unknown Source)
at javax.swing.JComponent.paintChildren(Unknown Source)
at javax.swing.JComponent.paint(Unknown Source)
at javax.swing.JComponent.paintChildren(Unknown Source)
at javax.swing.JComponent.paint(Unknown Source)
at javax.swing.JLayeredPane.paint(Unknown Source)
at javax.swing.JComponent.paintChildren(Unknown Source)
at javax.swing.JComponent.paintToOffscreen(Unknown Source)
at javax.swing.RepaintManager$PaintManager.paintDoubleBuffered(Unknown Source)
at javax.swing.RepaintManager$PaintManager.paint(Unknown Source)
at javax.swing.RepaintManager.paint(Unknown Source)
at javax.swing.JComponent.paint(Unknown Source)
at java.awt.GraphicsCallback$PaintCallback.run(Unknown Source)
at sun.awt.SunGraphicsCallback.runOneComponent(Unknown Source)
at sun.awt.SunGraphicsCallback.runComponents(Unknown Source)
at java.awt.Container.paint(Unknown Source)
at java.awt.Window.paint(Unknown Source)
at javax.swing.RepaintManager$4.run(Unknown Source)
at javax.swing.RepaintManager$4.run(Unknown Source)
at java.security.AccessController.doPrivileged(Native Method)
at java.security.ProtectionDomain$1.doIntersectionPrivilege(Unknown Source)
at javax.swing.RepaintManager.paintDirtyRegions(Unknown Source)
at javax.swing.RepaintManager.paintDirtyRegions(Unknown Source)
at com.servoy.j2db.util.gui.OverlapRepaintManager.paintDirtyRegions(OverlapRepaintManager.java:102)
at javax.swing.RepaintManager.prePaintDirtyRegions(Unknown Source)
at javax.swing.RepaintManager.access$1300(Unknown Source)
at javax.swing.RepaintManager$ProcessingRunnable.run(Unknown Source)
at java.awt.event.InvocationEvent.dispatch(Unknown Source)
at java.awt.EventQueue.dispatchEventImpl(Unknown Source)
at java.awt.EventQueue.access$500(Unknown Source)
at java.awt.EventQueue$3.run(Unknown Source)
at java.awt.EventQueue$3.run(Unknown Source)
at java.security.AccessController.doPrivileged(Native Method)
at java.security.ProtectionDomain$1.doIntersectionPrivilege(Unknown Source)
at java.awt.EventQueue.dispatchEvent(Unknown Source)
at java.awt.EventDispatchThread.pumpOneEventForFilters(Unknown Source)
at java.awt.EventDispatchThread.pumpEventsForFilter(Unknown Source)
at java.awt.EventDispatchThread.pumpEventsForHierarchy(Unknown Source)
at java.awt.EventDispatchThread.pumpEvents(Unknown Source)
at java.awt.EventDispatchThread.pumpEvents(Unknown Source)
at java.awt.EventDispatchThread.run(Unknown Source)

History

#1

Updated by Lambert Willemsen about 9 years ago

Application server Servoy 7 with output PDF :

SEVERE: Throwable
java.rmi.ServerError: Error occurred in server thread; nested exception is:
java.lang.NoSuchMethodError: org.apache.batik.dom.AbstractDOMImplementation.registerFeature(Ljava/lang/String;Ljava/lang/Object;)V
at sun.rmi.server.UnicastServerRef.dispatch(Unknown Source)
at sun.rmi.transport.Transport$1.run(Unknown Source)
at sun.rmi.transport.Transport$1.run(Unknown Source)
at java.security.AccessController.doPrivileged(Native Method)
at sun.rmi.transport.Transport.serviceCall(Unknown Source)
at sun.rmi.transport.tcp.TCPTransport.handleMessages(Unknown Source)
at sun.rmi.transport.tcp.TCPTransport$ConnectionHandler.run0(Unknown Source)
at sun.rmi.transport.tcp.TCPTransport$ConnectionHandler.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)
at sun.rmi.transport.StreamRemoteCall.exceptionReceivedFromServer(Unknown Source)
at sun.rmi.transport.StreamRemoteCall.executeCall(Unknown Source)
at sun.rmi.server.UnicastRef.invoke(Unknown Source)
at com.servoy.plugins.jasperreports.JasperReportsServer_Stub.getJasperBytes(Unknown Source)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
at java.lang.reflect.Method.invoke(Unknown Source)
at com.servoy.j2db.util.AbstractRemoteInvocationHandler.invokeMethod(AbstractRemoteInvocationHandler.java:77)
at com.servoy.j2db.util.ThreadingRemoteInvocationHandler$1.run(ThreadingRemoteInvocationHandler.java:79)
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.NoSuchMethodError: org.apache.batik.dom.AbstractDOMImplementation.registerFeature(Ljava/lang/String;Ljava/lang/Object;)V
at org.apache.batik.dom.svg.SVGDOMImplementation.<init>(SVGDOMImplementation.java:93)
at org.apache.batik.dom.svg.SVGDOMImplementation.<clinit>(SVGDOMImplementation.java:1596)
at org.apache.batik.dom.svg.SAXSVGDocumentFactory.<init>(SAXSVGDocumentFactory.java:120)
at net.sf.jasperreports.renderers.BatikRenderer.ensureSvg(BatikRenderer.java:200)
at net.sf.jasperreports.renderers.BatikRenderer.ensureSvg(BatikRenderer.java:234)
at net.sf.jasperreports.renderers.BatikRenderer.getDimension(BatikRenderer.java:152)
at net.sf.jasperreports.engine.export.JRPdfExporter.exportImage(JRPdfExporter.java:1403)
at net.sf.jasperreports.engine.export.JRPdfExporter.exportElements(JRPdfExporter.java:823)
at net.sf.jasperreports.engine.export.JRPdfExporter.exportFrame(JRPdfExporter.java:2633)
at net.sf.jasperreports.engine.export.JRPdfExporter.exportElements(JRPdfExporter.java:831)
at net.sf.jasperreports.engine.export.JRPdfExporter.exportPage(JRPdfExporter.java:787)
at net.sf.jasperreports.engine.export.JRPdfExporter.exportReportToStream(JRPdfExporter.java:701)
at net.sf.jasperreports.engine.export.JRPdfExporter.exportReport(JRPdfExporter.java:396)
at com.servoy.plugins.jasperreports.JasperReportRunner.getJasperBytes(JasperReportRunner.java:306)
at com.servoy.plugins.jasperreports.JasperReportsServer.getJasperBytes(JasperReportsServer.java:219)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
at java.lang.reflect.Method.invoke(Unknown Source)
at sun.rmi.server.UnicastServerRef.dispatch(Unknown Source)
at sun.rmi.transport.Transport$1.run(Unknown Source)
at sun.rmi.transport.Transport$1.run(Unknown Source)
at java.security.AccessController.doPrivileged(Native Method)
at sun.rmi.transport.Transport.serviceCall(Unknown Source)
at sun.rmi.transport.tcp.TCPTransport.handleMessages(Unknown Source)
at sun.rmi.transport.tcp.TCPTransport$ConnectionHandler.run0(Unknown Source)
at sun.rmi.transport.tcp.TCPTransport$ConnectionHandler.run(Unknown Source)
... 3 more

#2

Updated by Johan Compagner about 9 years ago

it seems to me that there are 2 different jars on the system of batik-dom.jar or batik-svg-dom.jar

because this is not directly jasper reports error but a error in the apache batik project that 1 class (in batik-svg-dom) accesses another one (in batik-dom.jar) and that class is not really he same version that one or the other expects.

I quickly checked the jars in the jasper reports that we ship and it seems that they do have really the same version and also exactly the same compile date.

So do you somehow have more plugins or jars somehwere that also uses batik?

#3

Updated by Lambert Willemsen about 9 years ago

Yes, you're right.
We now see there is a batik-dom collision with the IT2b-Gantt plugin !

How can that be fixed ?

#4

Updated by Johan Compagner about 9 years ago

you can only use 1, can you remove the one from gant?
Or overwrite the one from gant with the one from jasper?

does gant only have that batik-dom not the other one?

#5

Updated by Lambert Willemsen about 9 years ago

The JGantt.jar (from Netronic) uses only the batik-dom and not the batik-svg-dom.
Is there a nice and easy way to isolate jar libraries / eliminate collisions / request jar lib version with import in java (jws) ?
I can image this is a common / general problem when using open sourced jar libraries.

#6

Updated by Johan Compagner about 9 years ago

no thats all 1 big classloader, we don't have something like osgi on the client or server.

The only way to fix this is to use the same libs everywhere so copy the one from jasper over the one from jgantt
and see if then jgantt still works.

If that is not the case then we need to upgrade all the jars for the jasper plugin to the version that jgantt uses, not sure if thats a drop in replacement or if we have to change code for that.

#7

Updated by Johan Compagner about 9 years ago

can you send or attach here the batik file that jgantt has? Is that the 1.8 release?

#8

Updated by Lambert Willemsen about 9 years ago

We forwarded the question / issue to Netronic support.
They use an older version of the batik-dom...

#9

Updated by Lambert Willemsen about 7 years ago

To close this one: Netronic removed the batik stuff from their build (they did not use it).
Problem solved.

Also available in: Atom PDF