| Author |
org.springframework.beans.NotReadablePropertyException
|
indu iyengar
Ranch Hand
Joined: Jul 30, 2010
Posts: 115
|
|
Hi all,
am trying to integrate spring2.5 with hibernate . Code of dispatcher servlet is ... please tell me what's the problem in my code waiting for your reply
|
thanks ,
Indu
|
 |
Prasad Krishnegowda
Ranch Hand
Joined: Apr 25, 2010
Posts: 503
|
|
Hi Indu,
There is no property such as hibernate.connection.driver_class or other properties in org.springframework.jdbc.datasource.DriverManagerDataSource, which you have declared in datasource. So you are getting NotReadablePropertyException. It is having properties driverClassName,url,username and password. Try changing to this.
P:S: I would recommend you to move all the hibernate and other application related to beans to applicationContext.xml and use ContextLoaderListener to initialize it.
|
Regards, Prasad
SCJP 5 (93%)
|
 |
indu iyengar
Ranch Hand
Joined: Jul 30, 2010
Posts: 115
|
|
|
Thanks Prasad, it works like a charm. But why are you suggesting to use applicationContext.xml instead of spring-config ?
|
 |
Prasad Krishnegowda
Ranch Hand
Joined: Apr 25, 2010
Posts: 503
|
|
|
Just for the purpose of readability, because hibernate beans are application specific beans, the spring-dispatcher-servlet.xml, contains the handler mappings. If the application grows big, this would help in readability.
|
 |
 |
|
|
subject: org.springframework.beans.NotReadablePropertyException
|
|
|