refactor mybatis