Home  >  Forum  >  Spring
Post New Query

class path resource cannot be opened because it does not exist


joined on
April 23,2013
Asked on April 23,2013
Hi All,

I am new to spring and stuck with the error. I reading an external property file for database properties.

Caused by: java.io.FileNotFoundException: class path resource cannot be opened because it does not exist
at org.springframework.core.io.ClassPathResource.getInputStream(ClassPathResource.java:158)
at org.springframework.core.io.support.PropertiesLoaderSupport.loadProperties(PropertiesLoaderSupport.java:181)
at org.springframework.core.io.support.PropertiesLoaderSupport.mergeProperties(PropertiesLoaderSupport.java:161)
at org.springframework.beans.factory.config.PropertyResourceConfigurer.postProcessBeanFactory(PropertyResourceConfigurer.java:78)
... 6 more

joined on
April 15,2013
Replied on April 23,2013

Hi Ria,
The error may be because of

1.  There is no property file in classpath.
2.  You have misspelled the file name.


Check at your end.
joined on
April 15,2013
Replied on April 23,2013

Write Answer









Copyright ©2017 concretepage.com, all rights reserved |Privacy Policy | Contact Us