Reputation: 4773
I am getting this error when I am trying to run my application using eclipse.
org.springframework.beans.factory.BeanInitializationException: Could not load properties
and this is my configuration inside spring-servlet.xml
<context:property-placeholder location="classpath:application.properties" />
and my project folder structure is
src
--main
-- java
application.properties
Webcontent
--WEB-INF
--jsp
--lib
I build this project using POM.xml
war file is created inside target folder
Please let me know if you need more information.
Upvotes: 0
Views: 6203
Reputation: 279990
It doesn't look like the file is anywhere that would be added to the WAR. Put it under src/main/resources
, which is the conventional Maven location for non-source code resources.
Upvotes: 2