MyBatis启动报Cause: org.apache.ibatis.builder.BuilderException: Error resolving class. Cause: org.apache.ibatis.type.TypeException: Could not resolve type alias 'xxxx'.

mybatis-plus:
** # 搜索指定包别名,对指定报名下的所有实体 进行Alias,就可以在mapper.xml中使用alias来设置parameterType参数**
typeAliasesPackage: com.rcs.**.domain

** # 配置mapper的扫描,找到所有的mapper.xml映射文件,对该目录下的所有mapper.xml进行扫描装入Mappers中 **
mapperLocations: classpath:mapper/**/Mapper.xml
** # 加载全局的配置文件,读取mybatis的全局配置文件地址 **
configLocation: classpath:mybatis/mybatis-config.xml

mybatis-config.xml示例

posted @ 2024-08-30 13:58  vello  阅读(390)  评论(0)    收藏  举报