• Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Problem in finding the path of hibernate.conf.xml file...urgent please

 
Vinod Vinu
Ranch Hand
Posts: 217
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
iam getting the following error:-

PATH -->>>/hibernate.conf.xml
************ in the session factory *******************
Aug 31, 2009 2:49:44 PM org.hibernate.cfg.Configuration configure
INFO: configuring from resource: /hibernate.conf.xml
Aug 31, 2009 2:49:44 PM org.hibernate.cfg.Configuration getConfigurationInputStream
INFO: Configuration resource: /hibernate.conf.xml
Aug 31, 2009 2:49:44 PM org.apache.struts.action.RequestProcessor processException
WARNING: Unhandled Exception thrown: class java.lang.NullPointerException
Aug 31, 2009 2:49:44 PM org.apache.catalina.core.StandardWrapperValve invoke
SEVERE: Servlet.service() for servlet action threw exception
java.lang.NullPointerException
at action.LoginAction.execute(LoginAction.java:55)
at org.apache.struts.action.RequestProcessor.processActionPerform(RequestProcessor.java:421)
at org.apache.struts.action.RequestProcessor.process(RequestProcessor.java:226)
at org.apache.struts.action.ActionServlet.process(ActionServlet.java:1164)
at org.apache.struts.action.ActionServlet.doPost(ActionServlet.java:415)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:710)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:803)
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:269)
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:188)
at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:213)
at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:174)
at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:127)
at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:117)
at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:108)
at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:174)
at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:874)
at org.apache.coyote.http11.Http11BaseProtocol$Http11ConnectionHandler.processConnection(Http11BaseProtocol.java:665)
at org.apache.tomcat.util.net.PoolTcpEndpoint.processSocket(PoolTcpEndpoint.java:528)
at org.apache.tomcat.util.net.LeaderFollowerWorkerThread.runIt(LeaderFollowerWorkerThread.java:81)
at org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPool.java:689)
at java.lang.Thread.run(Thread.java:595)
Aug 31, 2009 2:50:08 PM org.apache.catalina.loader.WebappClassLoader modified
SEVERE: Resource '/WEB-INF/classes/hibernate.conf.xml' is missing
Aug 31, 2009 2:50:08 PM org.apache.catalina.core.StandardContext reload
INFO: Reloading this Context has started
Aug 31, 2009 2:50:08 PM org.apache.catalina.loader.WebappClassLoader validateJarFile
INFO: validateJarFile(D:\VinodNairWorkspace\.metadata\.plugins\org.eclipse.wst.server.core\tmp0\webapps\Hibernate\WEB-INF\lib\servlet-api.jar) - jar not loaded. See Servlet Spec 2.3, section 9.7.2. Offending class: javax/servlet/Servlet.class
 
Vijitha Kumara
Bartender
Pie
Posts: 3930
21
Chrome Fedora Hibernate
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Main config file is hibernate.cfg.xml, Can you show us your directory heirarchy inside the web container?
 
Nishan Patel
Ranch Hand
Posts: 689
Eclipse IDE Java Scala
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi,

Welcome to the Java Ranch....

Can you please tell us where is your hibernate.conf.xml location at your deployment environment ???

 
Cameron Wallace McKenzie
author and cow tipper
Saloon Keeper
Posts: 4968
1
Hibernate Spring Tomcat Server
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
SEVERE: Resource '/WEB-INF/classes/hibernate.conf.xml' is missing


That's pretty explicit!

Often people put the config file in their source directory, but it doesn't get moved to the classes directory at build time - instead, only compiled Java classes do. Make sure the file is on your runtime classpath, not just your design time classpath.
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic