This week's giveaway is in the JDBC forum.
We're giving away four copies of Java Database Connections & Transactions (e-book only) and have Marco Behler on-line!
See this thread for details.
Win a copy of Java Database Connections & Transactions (e-book only) this week in the JDBC forum!
  • 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 all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Devaka Cooray
  • Knute Snortum
  • Paul Clapham
  • Tim Cooke
Sheriffs:
  • Liutauras Vilda
  • Jeanne Boyarsky
  • Bear Bibeault
Saloon Keepers:
  • Tim Moores
  • Stephan van Hulst
  • Ron McLeod
  • Piet Souris
  • Frits Walraven
Bartenders:
  • Ganesh Patekar
  • Tim Holloway
  • salvin francis

org.springframework.beans.factory.BeanCreationException  RSS feed

 
Ranch Hand
Posts: 33
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi,

I m trying to connect database from my spring application and getting below exception :

org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'uriMapping' defined in ServletContext resource [/WEB-INF/ergts-servlet.xml]: Initialization of bean failed; nested exception is org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'loginActionController' defined in ServletContext resource [/WEB-INF/ergts-servlet.xml]: Cannot resolve reference to bean 'projectService' while setting bean property 'projectService'; nested exception is org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'projectService' defined in ServletContext resource [/WEB-INF/ergts-servlet.xml]: Error setting property values; nested exception is org.springframework.beans.NotWritablePropertyException: Invalid property 'projectDAO' of bean class [com.zensar.ergts.service.impl.ProjectServiceImpl]: Bean property 'projectDAO' is not writable or has an invalid setter method. Does the parameter type of the setter match the return type of the getter?
Caused by: org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'loginActionController' defined in ServletContext resource [/WEB-INF/ergts-servlet.xml]: Cannot resolve reference to bean 'projectService' while setting bean property 'projectService'; nested exception is org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'projectService' defined in ServletContext resource [/WEB-INF/ergts-servlet.xml]: Error setting property values; nested exception is org.springframework.beans.NotWritablePropertyException: Invalid property 'projectDAO' of bean class [com.zensar.ergts.service.impl.ProjectServiceImpl]: Bean property 'projectDAO' is not writable or has an invalid setter method. Does the parameter type of the setter match the return type of the getter?
Caused by: org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'projectService' defined in ServletContext resource [/WEB-INF/ergts-servlet.xml]: Error setting property values; nested exception is org.springframework.beans.NotWritablePropertyException: Invalid property 'projectDAO' of bean class [com.zensar.ergts.service.impl.ProjectServiceImpl]: Bean property 'projectDAO' is not writable or has an invalid setter method. Does the parameter type of the setter match the return type of the getter?
Caused by: org.springframework.beans.NotWritablePropertyException: Invalid property 'projectDAO' of bean class [com.zensar.ergts.service.impl.ProjectServiceImpl]: Bean property 'projectDAO' is not writable or has an invalid setter method. Does the parameter type of the setter match the return type of the getter?

Can any one please help me out. Any Pointers would be a great help.

Thanks in Advance,
Sumeet Gupta


 
Ranch Hand
Posts: 1374
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hello Sumit,
Make sure you beans are mapped properly. Exception says it can't resolve projectService bean. Check your mappings twice. I am pretty confident about it and I would be interested seeing your ergts-servlet.xml file.
 
sumeet gupta
Ranch Hand
Posts: 33
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi Vishal,

Thanks for the response, my error got resolved now.

Thanks,
Sumeet Gupta
 
Vikas Kapoor
Ranch Hand
Posts: 1374
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Nice to hear.
 
When it is used for evil, then watch out! When it is used for good, then things are much nicer. Like this tiny ad:
how do I do my own kindle-like thing - without amazon
https://coderanch.com/t/711421/engineering/kindle-amazon
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!