I am on a project that uses both Mybatis (for persisting java to database) and Mybatis Generator (to automatically generate the mapper xml files and java i
I had this task in Spring Boot project and was resolved bellow
In mybatis/*.xml files i changed generated like this 
in application.properties i have
mybatis.mapper-locations=classpath*:mybatis/*.xml
mybatis.type-aliases-package=news.project.demo.models