• Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Hibernate with Tomcat NoClassDefFoundError

 
Susilo Saja
Ranch Hand
Posts: 91
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi,
I'm new to Hibernate, and I'm trying to use it with Tomcat.
I got this error :
java.lang.NoClassDefFoundError: javax/transaction/Synchronization
I know this class is in j2ee.jar, so I put it in the lib directory of my webapp. But I still get the same error.
Can somebody help?
Susilo
 
Susilo Saja
Ranch Hand
Posts: 91
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I've found it. It turns out that the j2ee.jar is not loaded because of conflict with other jar
 
Stephen Lock
Greenhorn
Posts: 1
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
How did you fix it?
I have come across the same problem, and can't work out a solution, what jar was it conflicting with, and what was your fix?!
Cheers
Stephen
 
Dalton Camargo
Greenhorn
Posts: 2
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi friends!
For fix this error, you need put jta.jar in your classpath!
I hope help you.
 
roro steph
Greenhorn
Posts: 3
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi,
how did you solve it ?
I tried to put jta.jar into server classpath, and i 've got the same error !!
Help me please ....
Thanks
 
Rodrigo Branas
Greenhorn
Posts: 1
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi dudes,
i've the same problem and fix it just adding to the classpath jta.jar =)
[]s
 
John Reynolds
Greenhorn
Posts: 1
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Updating in case anyone finds this helpful. The simple solution is that j2ee.jar was missing from the classpath.

I just migrated from Java 1.4 to Java 1.5 and from Tomcat 4 to Tomcat 5 and Sun does not have a j2ee distribution for 1.5 yet (at least not that i could find).

so whereas the j2ee.jar was in my Sun/AppServer/lib path before when starting tomcat4, it was not part of the java lib when starting tomcat 5 because java 1.5 lib did not come with j2ee.jar

JR
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic