NoSuchMethodError: org.jboss.logging.Logger.debugf NoSuchMethodError: org.jboss.logging.Logger.debugf spring spring

NoSuchMethodError: org.jboss.logging.Logger.debugf


hibernate-entitymanager brought in jboss-logging as a dependency, but it is not the most up-to-date version and does not have that method implemented. It looks like you do not need jboss-logging, so try excluding it:

<dependency>    <groupId>org.hibernate</groupId>    <artifactId>hibernate-entitymanager</artifactId>    <version>5.0.1.Final</version>    <exclusions>        <exclusion>            <groupId>org.jboss.logging</groupId>            <artifactId>jboss-logging</artifactId>        </exclusion>    </exclusions></dependency>

Or if it turns out that you need jboss-logging for hibernate, then add a later version of jboss-logging as an additional dependency.

<dependency>    <groupId>org.jboss.logging</groupId>    <artifactId>jboss-logging</artifactId>    <version>3.3.0.Final</version></dependency>


I had a similar issue, I was able to fix it by creating a glassfish-web.xml file in the WEB-INF directory. The contents of the file are shown below:

<?xml version="1.0" encoding="UTF-8"?><!DOCTYPE glassfish-web-app PUBLIC "-//GlassFish.org//DTD GlassFish Application Server 3.1 Servlet 3.0//EN" "http://glassfish.org/dtds/glassfish-web-app_3_0-1.dtd"><glassfish-web-app>     <class-loader delegate="false"/></glassfish-web-app>

This ensures that glassfish does not load it's internal libraries, but libraries from your project.


The method org.jboss.logging.Logger.debugf is only available in the jboss-logging version 3.3.0, if you have this dependency in your project also you have to check that your GlassFish server also have the same version. I had the same error message and I solved it replacing the jboss-logging.jar at the glassfish installation folder because this jar is a previous version and it does not have the needed method. For example, I have the jar in the following path:

C:\Program Files\glassfish-4.1.1\glassfish\modules\jboss-logging.jar

I deleted the old jar and I put the new jar with same name but with the version 3.3.0. Just restart the GlassFish server and it will take the new jar version and that's all.