question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Could not open ServletContext resource [/mybatis-config.xml]

See original GitHub issue

I will mybatis-config.xml profiling in src/main/resources/*, When start being given Could not open ServletContext resource [/mybatis-config.xml] As can be seen from the annex screenshot Description qq 20160121135026

Issue Analytics

  • State:closed
  • Created 8 years ago
  • Comments:13 (2 by maintainers)

github_iconTop GitHub Comments

3reactions
eddumelendezcommented, Feb 1, 2016

In a web application we must use classpath: prefix

spring.datasource.schema=classpath:import.sql
mybatis.config=classpath:mybatis-config.xml
1reaction
zhuxinjuncommented, Jan 27, 2016

加 classpath: 在路径前边就可以了 @xiaoxing598

Read more comments on GitHub >

github_iconTop Results From Across the Web

Could not open ServletContext resource [/mybatis-config.xml]
application.properties mybatis config spring.datasource.schema=import.sql mybatis.config-location=mybatis-config.xml logging.level.root=WARN ...
Read more >
Could not open ServletContext resource [/classpath*:WEB-INF ...
5 and MyBatis 3.2.7 with maven. I have my myBatis-config.xml file under WEB-INF/myBatis folder. While trying to create the sqlSessionFactory ...
Read more >
Maven – Spring+ MyBatis+ mvn Project , java.io ... - iTecNote
FileNotFoundException : Could not open ServletContext resource [/myBatis/myBatis-config.xml] at org.springframework.beans.factory.support.
Read more >
Could not open ServletContext resource [/mybatis-config.xml]
Could not open ServletContext resource [/mybatis-config.xml] ; sqlSessionFactory ; property name · dataSource ; property name · configLocation ...
Read more >
Could not open ServletContext resource - CodeAntenna
说明要不文件名有误,要不该文件的路径设置有误。进入spring-dao.xml文件查看相关配置... Could not open ServletContext resource [/mybatis-config.xml].
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found