• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
Bartenders:
  • Mikalai Zaikin

Hibernate with Tomcat NoClassDefFoundError

 
Ranch Hand
Posts: 91
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • 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
    Number of slices to send:
    Optional 'thank-you' note:
  • 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
 
Greenhorn
Posts: 1
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • 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
 
Greenhorn
Posts: 2
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi friends!
For fix this error, you need put jta.jar in your classpath!
I hope help you.
 
Greenhorn
Posts: 3
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • 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
 
Greenhorn
Posts: 1
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi dudes,
i've the same problem and fix it just adding to the classpath jta.jar =)
[]s
 
Greenhorn
Posts: 1
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • 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
 
She still doesn't approve of my superhero lifestyle. Or this shameless plug:
a bit of art, as a gift, that will fit in a stocking
https://gardener-gift.com
reply
    Bookmark Topic Watch Topic
  • New Topic