码迷,mamicode.com
首页 > 编程语言 > 详细

Exception in thread "main" java.lang.NoClassDefFoundError: org/apache/commons/logging/LogFactory

时间:2016-05-05 17:27:25      阅读:162      评论:0      收藏:0      [点我收藏+]

标签:

Exception in thread "main" java.lang.NoClassDefFoundError: org/apache/commons/logging/LogFactory
	at org.springframework.beans.factory.support.DefaultSingletonBeanRegistry.<init>(DefaultSingletonBeanRegistry.java:81)
	at org.springframework.beans.factory.support.FactoryBeanRegistrySupport.<init>(FactoryBeanRegistrySupport.java:43)
	at org.springframework.beans.factory.support.AbstractBeanFactory.<init>(AbstractBeanFactory.java:176)
	at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.<init>(AbstractAutowireCapableBeanFactory.java:159)
	at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.<init>(AbstractAutowireCapableBeanFactory.java:170)
	at org.springframework.beans.factory.support.DefaultListableBeanFactory.<init>(DefaultListableBeanFactory.java:166)
	at org.springframework.beans.factory.xml.XmlBeanFactory.<init>(XmlBeanFactory.java:78)
	at org.springframework.beans.factory.xml.XmlBeanFactory.<init>(XmlBeanFactory.java:67)
	at com.spring.test.Main.main(Main.java:16)
Caused by: java.lang.ClassNotFoundException: org.apache.commons.logging.LogFactory
	at java.net.URLClassLoader$1.run(URLClassLoader.java:200)
	at java.security.AccessController.doPrivileged(Native Method)
	at java.net.URLClassLoader.findClass(URLClassLoader.java:188)
	at java.lang.ClassLoader.loadClass(ClassLoader.java:307)
	at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:301)
	at java.lang.ClassLoader.loadClass(ClassLoader.java:252)
	at java.lang.ClassLoader.loadClassInternal(ClassLoader.java:320)
	... 9 more


解决:

  把common-logging.jar包添加到buildpath

  链接地址:common-logging.jar

  密码:isll    

Exception in thread "main" java.lang.NoClassDefFoundError: org/apache/commons/logging/LogFactory

标签:

原文地址:http://www.cnblogs.com/changyaoguo/p/5462390.html

(0)
(0)
   
举报
评论 一句话评论(0
登录后才能评论!
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!