[11/04 15:02] Exception encountered during context initialization - cancelling refresh attempt
org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'sqlSessionFactory' defined in class path resource [applicationContext.xml]: Invocation of init method failed; nested exception is org.springframework.core.NestedIOException: Failed to parse mapping resource: 'URL [jar:file:/D:/STHworkspace/.metadata/.plugins/org.eclipse.wst.server.core/tmp0/wtpwebapps/ocPortal/WEB-INF/lib/ocService-1.0.0-SNAPSHOT.jar!/com/online/college/core/consts/dao/TJHourMapper.xml]'; nested exception is org.apache.ibatis.builder.BuilderException: Error creating document instance. Cause: org.xml.sax.SAXParseException; lineNumber: 4; columnNumber: 65; 必须为元素类型 "mapper" 声明属性 "didspace"。
出现这个错误的原因是SSM项目中Mapper.xml文件中第4行的mapper声明属性不正确,是因为我查找替换时把 “namespace”改成了“didspace”