reset password
Author Message
rain0204
Posts: 6
Posted 18:15 Oct 17, 2010 |

I am getting the error below when I tried to run FileTest.java

Exception in thread "main" org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'fileTest' defined in class path resource [filetest.xml]: Cannot resolve reference to bean 'userDao' while setting bean property 'userDao'; nested exception is org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'userDao' defined in class path resource [filetest.xml]: Cannot resolve reference to bean 'transactionManager' while setting bean property 'transactionManager'; nested exception is org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'transactionManager' defined in class path resource [filetest.xml]: Cannot resolve reference to bean 'sessionFactory' while setting bean property 'sessionFactory'; nested exception is org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'sessionFactory' defined in class path resource [filetest.xml]: Invocation of init method failed; nested exception is net.sf.ehcache.CacheException: Error configuring from file:/C:/CS520/workspace/csns/build/classes/ehcache.xml. Initial cause was Error configuring from input stream. Initial cause was null:20: Element <defaultCache> does not allow attribute "maxElementsOnDisk".
 

Please Help

cysun
Posts: 2935
Posted 18:38 Oct 17, 2010 |

Removing the maxElementsOnDisk line in ehcache.xml should fix the problem.

Another student also had the same problem but I haven't figured out why.