• 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

class not found exception

 
Greenhorn
Posts: 1
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi i am getting the following error. I am not understanding how to resolve it.


ERROR IS



CODE IS

applicationContext.xml (its in WEBINF folder)



All other hbm files are loading. I have added new hbm file i.e., PtmFile.hbm.xml and its not working. I am not understanding why its not loading ?

 
Ranch Hand
Posts: 300
Eclipse IDE Java
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi Maganti,

I found this in stack trace "Caused by: java.io.FileNotFoundException: class path resource [map/PtmFile.hbm.xml] cannot be opened because it does not exist"

Please put the hbm file in class path or particular location and redeploy the application.. As its says file not found...

 
Bartender
Posts: 1682
7
Android Mac OS X IntelliJ IDE Spring Linux
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
in addition to what jatan said make sure the servlet-api depedency in your POM is scoped to provided. Your application should not include this jar when it is built as its Tomcat has its own.
 
reply
    Bookmark Topic Watch Topic
  • New Topic