NoClassDefFoundError: org/jboss/logging/Logger
When using the Apache Camel and Narayana JTA starters in Spring Boot, if you get this error when running your app:
org.springframework.beans.factory.BeanCreationException: Error creating bean with name ‘narayanaConfiguration’ defined in class path resource [org/springframework/boot/autoconfigure/transaction/jta/NarayanaJtaConfiguration.class]: Invocation of init method failed; nested exception is java.lang.RuntimeException: java.lang.NoClassDefFoundError: org/jboss/logging/Logger
You may need to add the spring-boot-starter-web
dependency to your Maven POM, like this:
<dependency>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-starter-web</artifactId>
</dependency>
This starter includes org.jboss.logging:jboss-logging:jar
, along with other dependencies.