nested exception is java.io.FileNotFoundException: Could not open ServletContext resource [/jdbc.pro

版权声明:本文为博主原创文章,未经博主允许不得转载。 https://blog.csdn.net/joker8023joker/article/details/78704776

问题所在:

Exception encountered during context initialization - cancelling refresh attempt: org.springframework.beans.factory.BeanInitializationException: Could not load properties; nested exception is java.io.FileNotFoundException: Could not open ServletContext resource [/jdbc.properties]


问题分析:

大概意思就是这个[/jdbc.properties]找不到。


问题解决:

在引入外部文件时,location加上classpath:



猜你喜欢

转载自blog.csdn.net/joker8023joker/article/details/78704776