0

After updating JavaMelody to its newest version (Version 1.62.0 was used previously), JBoss 6 logs an error on start up.

I have two dependencies in the ivy.xml

<dependency org="net.bull.javamelody" name="javamelody-core" rev="1.68.0" transitive="false" conf="ear-lib->default"/> 
<dependency org="org.jrobin" name="jrobin" rev="1.5.9" transitive="false" conf="ear-lib->default"/>  

and both of them as modules in the application.xml as well

<module> 
    <java>lib/javamelody-core-1.68.0.jar</java> 
</module> 
<module> 
    <java>lib/jrobin-1.5.9.jar</java> 
</module>

On startup JBoss 6 throws the following exceptions:

Error installing to Start: name=vfs:///C:/app/jboss-6.0.0.Final/server/default/deploy/intern.ear_WeldBootstrapBean state=Create: com.google.common.collect.ComputationException: org.jboss.weld.resources.spi.ResourceLoadingException: Error loading class net.bull.javamelody.internal.web.pdf.PdfAbstractReport  
...
Caused by: org.jboss.weld.resources.spi.ResourceLoadingException: Error loading class net.bull.javamelody.internal.web.pdf.PdfAbstractReport 
...
Caused by: java.lang.NoClassDefFoundError: Lcom/lowagie/text/Document;  
...
Caused by: java.lang.ClassNotFoundException: com.lowagie.text.Document from BaseClassLoader@2f432a6b{vfs:///C:/app/jboss-6.0.0.Final/server/default/deploy/intern.ear}

If I add iText to ivy.xml and application .xml I get another error that the class WriteListener cannot be found.

The issue seems to be related with the introduction of PDF reports. Is there a way to exclude PDF reports from JavaMelody?

LordAnomander
  • 1,103
  • 6
  • 16
  • No the problem is a missing class dependency. Here are the possible missing candidate: http://search.maven.org/#search%7Cga%7C1%7Cfc%3A%22com.lowagie.text.Document%22 – Mark O'Connor Jul 12 '17 at 17:53

1 Answers1

1

I think that you are using JBoss version using CDI 1.0 (and not using CDI 1.1). There may be an incompatibility between your JBoss/CDI version and javamelody since 1.66 due to the presence of beans.xml and of MonitoringCdiInterceptor in javamelody.

So you may upgrade JBoss to a version using CDI 1.1 or downgrade javamelody to 1.65.0.

evernat
  • 1,713
  • 13
  • 18