INFO: Initializing Spring root WebApplicationContext
20:52:40,209 ERROR ContextLoader:215 - Context initialization failed
20:52:40,209 ERROR ContextLoader:215 - Context initialization failed
org.springframework.beans.factory.BeanDefinitionStoreException: Unexpected exception parsing XML document from class path resource [applicationContext.xml]; nested exception is java.lang.IllegalStateException: Context namespace element 'annotation-config' and its parser class [org.springframework.context.annotation.AnnotationConfigBeanDefinitionParser] are only available on JDK 1.5 and higher
出现这个问题是jdk版本过高,或者是spring2.6.5版本太低了,不适合annotion的注解。
解决方法,升级spring到sprng3.0以上即可。
特别是spring-test-2.5.6,换到spring3.0以上