Failed to load class org.slf4j.impl.StaticLogger 的解決方案

在hibernate + spring + struts 框架下,佈署在weblogic9下的時候報Failed to load class org.slf4j.impl.StaticLogger錯誤,最後問題解決。html

分析問題,因爲是找不包slf4j相應的jar包,所以是因爲少jar包的緣由。web

slf4j 官方有常見錯誤解答: http://www.slf4j.org/codes.html#log4j_version

得知此錯誤緣由是:spring

This error is reported when the org.slf4j.impl.StaticLoggerBinder class could not be loaded into memory. This happens when no appropriate SLF4J binding could be found on the class path. Placing one (and only one) of slf4j-nop.jar , slf4j-simple.jar , slf4j-log4j12.jar , slf4j-jdk14.jar or logback-classic.jar on the class path should solve the problem.app

 

故在官方下載 slf4j-1.5.2.zip 框架

解壓出slftj-nop-1.5.jar導入項目,後無報錯,問題解決。hibernate

相關文章
相關標籤/搜索