Incorrect resource mapping resulting in FileNotFoundException

java.io.FileNotFoundException
Javadoc
at org.springframework.web.context.support.ServletContextResource.getInputStream
(source)
at org.springframework.beans.factory.xml.XmlBeanDefinitionReader.loadBeanDefinitions
(source)

Typical Exception Messages

  1. Could not open ServletContext resource [/WEB-INF/applicationContext.xml]
  2. Could not open ServletContext resource [/WEB-INF/dispatcher-servlet.xml]
  3. Could not open ServletContext resource [/WEB-INF/spring-servlet.xml]
  4. Could not open ServletContext resource [/WEB-INF/dispatcherServlet-servlet.xml]
  5. Could not open ServletContext resource [/<NONE>]
  6. Could not open ServletContext resource [/WEB-INF/mvc-dispatcher-servlet.xml]
  7. Could not open ServletContext resource [/WEB-INF/spring-dispatcher-servlet.xml]
  8. Could not open ServletContext resource [/classPath*:Application.xml]
  9. Could not open ServletContext resource [/WEB-INF/classes/conf/security-applicationContext.xml]
  10. Could not open ServletContext resource [/WEB-INF/spring-security.xml]

Origin

ServletContextResource.getInputStream() has thrown a FileNotFoundException

java.io.FileNotFoundException
org.springframework.web.context.support.ServletContextResource.getInputStream
129Web pages

Similar

Specific cases

Solution

rahsan, 2 months ago

Ensure the resource that cannot be opened is properly mapped in your configuration file(web.xml, app-config.xml, etc..). Check this for farther clarification

External results for this pattern (99)

  1. mouezavia GitHub3 months ago
    Could not open ServletContext resource [/WEB-INF/servlet-context.xml]
    Show stack trace
  2. Could not open ServletContext resource [/WEB-INF/applicationContext.xml]
    Show stack trace
  3. sachwuvia GitHub3 months ago
    Could not open ServletContext resource [/WEB-INF/applicationContext.xml]
    Show stack trace
  4. Unknown authorvia algaworks.com3 months ago
    Could not open ServletContext resource [/WEB-INF/applicationContext.xml]
    Show stack trace
  5. gmeiner.mvia Stack Overflow3 months ago
    Could not open ServletContext resource [/WEB-INF/dispatcherServlet-servlet.xml]
    Show stack trace
  6. munnavia Stack Overflow3 months ago
    Could not open ServletContext resource [/WEB-INF/xfire-servlet.xml]
    Show stack trace
  7. Sam Jonesvia Stack Overflow3 months ago
    Could not open ServletContext resource [/<package name redacted>.TctWebApplication]
    Show stack trace
  8. Unknown authorvia bccn.net3 months ago
    Could not open ServletContext resource [/classPath*:Application.xml]
    Show stack trace
  9. Unknown authorvia bccn.net3 months ago
    Could not open ServletContext resource [/classPath*:Application.xml]
    Show stack trace
  10. Andrew Onischukvia Apache's JIRA Issue Tracker3 months ago
    Could not open ServletContext resource [/WEB-INF/classes/conf/security-applicationContext.xml]
    Show stack trace