mybatis-flex/mybatis-flex-core
wcc1433 c969ee388d
多环境导入相同 Mapper 冲突问题
创建多个环境,每个环境加载相同 Mapper (例如 RowMapper)会导致环境冲突。
代码:
// 环境实例1
MybatisFlexBootstrap client1 = ...;
client1.addMapper(RowMapper.class);
// 环境实例2:
MybatisFlexBootstrap client2 = // ;
client2.addMapper(RowMapper.class);

client1.getMapper(RowMapper.class);
// client2 拿到的永远都是 client1 的 RowMapper
client2.getMapper(RowMapper.class);
2025-05-25 15:40:10 +08:00
..
2025-03-19 18:25:12 +08:00