org.springframework.beans.factory.BeanDefinitionStoreException: Unexpected exception parsing XML document from file [C:/temp/tempworkspace/test-handler2/src/main/webapp/WEB-INF/spring/app-config.xml]; nested exception is java.lang.RuntimeException: Failed to load class from classpath

Searched on Google with the first line of a JAVA stack trace?

We can recommend more relevant solutions and speed up debugging when you paste your entire stack trace with the exception message. Try a sample exception.

Recommended solutions based on your search

Samebug tips

,
Expert tip

You need to add httpcore to your dependencies. Try adding version 4.3 or further.

,
via oracle.com by Unknown author

app tries to load in a class through its string name using forName method in class Class, findSystemClass method in class ClassLoader, loadClass method in class ClassLoader but no definition for the class with the specified name could be found

Solutions on the web

via Spring JIRA by Mike Youngstrom, 1 year ago
Unexpected exception parsing XML document from file [C:/temp/tempworkspace/test-handler2/src/main/webapp/WEB-INF/spring/app-config.xml]; nested exception is java.lang.RuntimeException: Failed to load class from classpath
via Spring JIRA by Mike Youngstrom, 1 year ago
Unexpected exception parsing XML document from file [C:/temp/tempworkspace/test-handler2/src/main/webapp/WEB-INF/spring/app-config.xml]; nested exception is java.lang.RuntimeException: Failed to load class from classpath
via Spring JIRA by Mike Youngstrom, 1 year ago
Unexpected exception parsing XML document from file [C:/temp/temp-stack-workspace-3/test-parse-error/src/main/webapp/WEB-INF/spring/app-config.xml]; nested exception is java.lang.ClassCastException: org.springframework.context.annotation.ScopedProxyMode cannot be cast to org.springframework.context.annotation.ScopedProxyMode
via Spring JIRA by Mike Youngstrom, 1 year ago
Unexpected exception parsing XML document from file [C:/temp/temp-stack-workspace-3/test-parse-error/src/main/webapp/WEB-INF/spring/app-config.xml]; nested exception is java.lang.ClassCastException: org.springframework.context.annotation.ScopedProxyMode cannot be cast to org.springframework.context.annotation.ScopedProxyMode
via Spring JIRA by Palam Garg, 1 year ago
Unexpected exception parsing XML document from file [D:/ProjectItrack4.0/iTrack/src/main/webapp/WEB-INF/spring/webmvc-config.xml]; nested exception is org.springframework.beans.factory.NoSuchBeanDefinitionException: No bean named 'org.springframework.web.servlet.handler.SimpleUrlHandlerMapping#iTrack#src/main/webapp/WEB-INF/spring/webmvc-config.xml#20' is defined
via Spring JIRA by Palam Garg, 1 year ago
Unexpected exception parsing XML document from file [D:/ProjectItrack4.0/iTrack/src/main/webapp/WEB-INF/spring/webmvc-config.xml]; nested exception is org.springframework.beans.factory.NoSuchBeanDefinitionException: No bean named 'org.springframework.web.servlet.handler.SimpleUrlHandlerMapping#iTrack#src/main/webapp/WEB-INF/spring/webmvc-config.xml#20' is defined
org.springframework.beans.factory.BeanDefinitionStoreException: Unexpected exception parsing XML document from file [C:/temp/tempworkspace/test-handler2/src/main/webapp/WEB-INF/spring/app-config.xml]; nested exception is java.lang.RuntimeException: Failed to load class from classpath
at java.net.URLClassLoader$1.run(URLClassLoader.java:202)
at java.security.AccessController.doPrivileged(Native Method)
at java.net.URLClassLoader.findClass(URLClassLoader.java:190)
at java.lang.ClassLoader.loadClass(ClassLoader.java:307)
at java.lang.ClassLoader.loadClass(ClassLoader.java:248)
at org.test.handler.CustomParser.parse(CustomParser.java:13)
at org.springframework.beans.factory.xml.NamespaceHandlerSupport.parse(NamespaceHandlerSupport.java:73)
at org.springframework.ide.eclipse.beans.core.internal.model.BeansConfig$ErrorSuppressingBeanDefinitionParserDelegate.parseCustomElement(BeansConfig.java:1244)
at org.springframework.beans.factory.xml.BeanDefinitionParserDelegate.parseCustomElement(BeanDefinitionParserDelegate.java:1325)
at org.springframework.beans.factory.xml.DefaultBeanDefinitionDocumentReader.parseBeanDefinitions(DefaultBeanDefinitionDocumentReader.java:136)
at org.springframework.beans.factory.xml.DefaultBeanDefinitionDocumentReader.registerBeanDefinitions(DefaultBeanDefinitionDocumentReader.java:93)
at org.springframework.ide.eclipse.beans.core.internal.model.BeansConfig$2.registerBeanDefinitions(BeansConfig.java:384)
at org.springframework.beans.factory.xml.XmlBeanDefinitionReader.doLoadBeanDefinitions(XmlBeanDefinitionReader.java:390)
at org.springframework.ide.eclipse.beans.core.internal.model.BeansConfig$2.loadBeanDefinitions(BeansConfig.java:371)
at org.springframework.ide.eclipse.beans.core.internal.model.BeansConfig$3.call(BeansConfig.java:414)
at org.springframework.ide.eclipse.beans.core.internal.model.BeansConfig$3.call(BeansConfig.java:1)
at java.util.concurrent.FutureTask$Sync.innerRun(FutureTask.java:303)
at java.util.concurrent.FutureTask.run(FutureTask.java:138)
at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:441)
at java.util.concurrent.FutureTask$Sync.innerRun(FutureTask.java:303)
at java.util.concurrent.FutureTask.run(FutureTask.java:138)
at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:886)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:908)
at java.lang.Thread.run(Thread.java:619)

Users with the same issue

Samebug visitor profile picture
Unknown user
Once, 1 year ago
Samebug visitor profile picture
Unknown user
Once, 1 year ago
Samebug visitor profile picture
Unknown user
2 times, 1 year ago
14 times, 2 months ago
Samebug visitor profile picture
Unknown user
Once, 2 months ago
2436 more bugmates

Know the solutions? Share your knowledge to help other developers to debug faster.