首页 > 代码库 > Initialization of bean failed; nested exception is java.lang.reflect.MalformedParameterizedTypeExcep

Initialization of bean failed; nested exception is java.lang.reflect.MalformedParameterizedTypeExcep

<style type="text/css" id="wiz_custom_css">body{ font-family: "Microsoft YaHei UI","Microsoft YaHei",SimSun,"Segoe UI",Tahoma,Helvetica,Sans-Serif,"Microsoft YaHei", Georgia,Helvetica,Arial,sans-serif,宋体, PMingLiU,serif; font-size: 10.5pt; line-height: 1.5;}html, body{ }h1 { font-size:1.5em; font-weight:bold;}h2 { font-size:1.4em; font-weight:bold;}h3 { font-size:1.3em; font-weight:bold;}h4 { font-size:1.2em; font-weight:bold;}h5 { font-size:1.1em; font-weight:bold;}h6 { font-size:1.0em; font-weight:bold;}img { border:0; max-width: 100%;}blockquote { margin-top:0px; margin-bottom:0px;}</style>Initialization of bean failed; nested exception is java.lang.reflect.MalformedParameterizedTypeExcep严重: Exception sending context initialized event to listener instance of class org.springframework.web.context.ContextLoaderListener?

org.springframework.beans.factory.BeanCreationException: Error creating bean with name ‘sqlSessionFactory‘ defined in class path resource [applicationContext.xml]: Initialization of bean failed; nested exception is java.lang.reflect.MalformedParameterizedTypeException?


原来是spring版本的问题,MyBatis-Spring只能在spring3.0版本上使用,如果用spring3.0以下版本就会出现该问题,建议将spring升级为3.0或改用ibatis2.0!



来自为知笔记(Wiz)