关于【jdbc.properties】cannot be opened because it does not exist
我手头有个别人给我的程序,我修改后台内容,但是一执行还是以前的结果,例如int a=4;改成a=5;执行后还是4.于是删除了classes文件。
但是重新部署启动tomcat之后。报错误org.springframework.beans.factory.BeanInitializationException: Could not load properties; nested exception is java.io.FileNotFoundException: class path resource [jdbc.properties] cannot be opened because it does not exist
我得jdbc.properties文件在src下。
applicationcontext.xml中配置如下:
<bean id="propertyConfigurer"class="org.springframework.beans.factory.config.PropertyPlaceholderConfigurer">
<property name="location">
<value>classpath:jdbc.properties</value>
</property>
</bean>
求大神解答,到底错在哪里了。