Win a copy of Design for the Mind this week in the Design forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Error: ERROR initServletBean, Context initialization failed

 
priyanka kulathilaka
Ranch Hand
Posts: 36
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
 
Prasad Krishnegowda
Ranch Hand
Posts: 667
4
Eclipse IDE Java Spring
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Can you paste your spring-servlet.xml and the list of jar files you are deploying?
 
priyanka kulathilaka
Ranch Hand
Posts: 36
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
 
Tommy Delson
Ranch Hand
Posts: 206
  • Likes 1
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
You're pasting a pom.xml file not the xlm file that you need for trouble shooting.

Basically an error "2011-07-14 14:48:54.576:INFO::No Transaction manager found - if your webapp requires one, please configure one." indicated that you're missing an application-context.xml file where you configure your app to connect with the data source and handle the transaction.

You need to have application-context.xml file, if you don't have one you need to create one. Refer to Spring reference of how to create one and configure. Below is an example that some information that you need to configure in the file.


For example,




Hope it help...
 
priyanka kulathilaka
Ranch Hand
Posts: 36
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
thanks tommy.,

here is my spring-servlet.xml


& here is my web.xml

 
Tommy Delson
Ranch Hand
Posts: 206
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I see there many problems in your spring-servlet.xml file, problems are on bean id="sessionFactory" , you didn't configure it probably. Therefore, it didn't load the information it looking when your run the app. It can easily fixed, refer to Spring document and other sources how to config it probably.

I recommend create a new separate xml file called applicationContext.xml for easy maintenance, wire it in web.xml along spring-servlet.xml. Moreover, refer to Spring document for more info on how to configure.

See my comments below for troubleshooting...



 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic