Caused by: java.lang.NoClassDefFoundError: Ljavax/transaction/TransactionManager;

Related searches

I read many posts about the error javax/transaction/TransactionManager, but none of those solutions fix my problem.

First thing to say is that I get that error when I deploy my web-application (made with Spring MVC and Hibernate) on the server. On my computer, with Eclipse and Tomcat 7 everything works.

Second thing to say is that on that server I have another web-application that's running under tomcat /root folder (this is a simple java application, that DOESN'T use neither Spring mvc nor Hibernate). The new application that i'm trying to deploy is running under another folder called /prova.

These are all the libraries of my application

Plus, according to what I read on some posts, I added to my lib folder:

1) jta-

2) hibernate3.3.1-jta-1.1.jar

3) javax.transaction.jar

In my xml file I have this bean that defines the transaction manager

<bean id="transactionManager" class="org.springframework.orm.hibernate3.HibernateTransactionManager">
     <property name="sessionFactory" ref="sessionFactory" />

Something strange is that in the server log the exact error is

Caused by: java.lang.NoClassDefFoundError: Ljavax/transaction/TransactionManager;

There's a L before javax/transaction/TransactionManager

Any idea?

Thank you

Don't worry with the "L", it just defines that the following is an object. You can find other letters :

B     byte (signed byte)
C     char (Unicode character)
D     double (double-precision floating-point value)
F     float (single-precision floating-point value)
I     int (integer)
J     long (long integer)
L<classname>;     reference (an instance of class <classname>)
S     short (signed short)
Z     boolean (true or false)
[     reference (one array dimension )

To come back to your problem, did you define your transaction manager whith something close to this :

<bean id="transactionManager" class="org.springframework.orm.hibernate4.HibernateTransactionManager" p:sessionFactory-ref="sessionFactory">

HibernateTransactionManager is an implementation of javax.transaction.TransactionManager

java.lang.NoClassDefFoundError: javax/transaction , java.lang.NoClassDefFoundError: javax/transaction/TransactionManager. Recently while trying to migrate one of the application from JDK6 to� Solution. The javax.transaction.TransactionManager is a class inside the J2EE SDK library “javaee.jar“, you are missing this jar file in your project classpath.. 1. J2EE SDK

you must add this dependency It is work


java.lang.NoClassDefFoundError: javax/transaction , Dismiss Join GitHub today. GitHub is home to over 50 million developers working together to host and review code, manage projects, and build software together.

This worked for me


java.lang.ClassNotFoundException: javax.transaction , Hi Ibrahim. Thanks for quick response. jta is the dependency in hibernate (I have hibernate3.6 and hibernate-annotation 3.4.) so when I add jta.jar it cause class loader problem i.e. typeMismatchException for transaction manager.

where is spring-data jars? It looks like spring-data-commons. Please, spend some time to learn how to use maven or gradle. It will save a lot of your time.

The javax.transaction.TransactionManager is a class inside the J2EE SDK library “ javaee.jar “, you are missing this jar file in your project classpath.

I am trying to port Spring Boot to Java9 and I am hitting an issue that looks like Maven specific. I've managed to trim down the problem to a simple class that doesn't involve Spring Boot

This is caused by missing of the “jta.jar“, usually happened in Hibernate transaction development. java.lang.NoClassDefFoundError: javax/transaction

Hi, As i am newbie in JBoss, please help me as i am getting the below error. 19:28:19,522 ERROR [AbstractKernelController] Error installing to

  • Hi man, I edited mypost, adding the bean of my transaction manager.
  • On your server, did you check that the libs in the classpath are the same than on your computer ? HibernateTransactionManager is provided by spring-orm, so it should be in the war. Maybe you should try adding spring-orm in tomcat external classpath to check that the one in the war is not skipped mysteriously ???
  • It came out the problem was the wrong name of the database. Now I don't get that error anymore. Thank you.