在配置hibernate时,如果配置为
<property name="mappingDirectoryLocations">
<list>
<value>classpath:com/test/pojo/</value>
</list>
</property>
时会出现 cannot be resolved to absolute file path because it does not reside in the 。。。。错误
更改为如下便可以解决问题
<property name="mappingLocations">
<list>
<value>classpath*:com/test/pojo/*.hbm.xml</value>
</list>
</property>