Hibernate:::Initial SessionFactory creation failed.org.hibernate.HibernateException: could not init listeners

Posted on 2011-09-05
Medium Priority
Last Modified: 2013-11-24

I am getting this exception in the console in the eclipse.

Initial SessionFactory creation failed.org.hibernate.HibernateException: could not init listener.

I am using Struts 2 with hibernate 3.
I am just using saveorupdate command to save to database.I am getting this exception,

Please some one help me..
I am strugging with this exception from 2 days.

If you need more details..please ask me...

Thanks a lot..

Question by:chaitu22
  • 2
  • 2
LVL 40

Expert Comment

by:Gurvinder Pal Singh
ID: 36486424
I guess there is some problem with mapping

please check the same

Author Comment

ID: 36492212
I have done the modfications..but now i am getting resource not found exception.
I have kept web.xml in web-inf folder.
I have kept struts.xml and hibernate.cfg.xml in WEB-INF/classes folder.

Please suggest.
"-//Apache Software Foundation//DTD Struts Configuration 2.0//EN"

    <!-- Configuration for the default package. -->
    <package name="default" extends="struts-default">
        <action name="LoginAction" class="com.first.LoginAction">
            <result name="input">/login.jsp</result>
            <result name="success">/success.jsp</result>

Open in new window

LVL 40

Accepted Solution

Gurvinder Pal Singh earned 2000 total points
ID: 36493460
No, struts.xml and hibernate.cfg.xml should be in WEB-INF folder

LVL 61

Expert Comment

by:Kevin Cross
ID: 36935256
This question has been classified as abandoned and is closed as part of the Cleanup Program. See the recommendation for more details.

Author Comment

ID: 36907106
You can go ahead and delete this!!

Featured Post

Free Tool: Site Down Detector

Helpful to verify reports of your own downtime, or to double check a downed website you are trying to access.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

Join & Write a Comment

I had a project requirement for a displaying a user workbench .This workbench would consist multiple data grids .In each grid the user will be able to see a large number of data. These data grids should allow the user to 1. Sort 2. Export the …
Basic understanding on "OO- Object Orientation" is needed for designing a logical solution to solve a problem. Basic OOAD is a prerequisite for a coder to ensure that they follow the basic design of OO. This would help developers to understand the b…
Viewers learn about the “for” loop and how it works in Java. By comparing it to the while loop learned before, viewers can make the transition easily. You will learn about the formatting of the for loop as we write a program that prints even numbers…
This video teaches viewers about errors in exception handling.

624 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question