2022-01-07 14:43:03.030 ERROR 18120 --- [schedule-pool-1] com.inkyi.system.service.SysLogService : Invalid bound statement (not found): com.inkyi.system.mapper.SysOperLogMapper.insertSelective
org.apache.ibatis.binding.BindingException: Invalid bound statement (not found): com.inkyi.system.mapper.SysOperLogMapper.insertSelective
at org.apache.ibatis.binding.MapperMethod$SqlCommand.<init>(MapperMethod.java:235) ~[mybatis-3.5.9.jar:3.5.9]
at org.apache.ibatis.binding.MapperMethod.<init>(MapperMethod.java:53) ~[mybatis-3.5.9.jar:3.5.9]
at org.apache.ibatis.binding.MapperProxy.lambda$cachedInvoker$0(MapperProxy.java:108) ~[mybatis-3.5.9.jar:3.5.9]
at java.base/java.util.concurrent.ConcurrentHashMap.computeIfAbsent(ConcurrentHashMap.java:1705) ~[na:na]
at org.apache.ibatis.util.MapUtil.computeIfAbsent(MapUtil.java:35) ~[mybatis-3.5.9.jar:3.5.9]
at org.apache.ibatis.binding.MapperProxy.cachedInvoker(MapperProxy.java:95) ~[mybatis-3.5.9.jar:3.5.9]
at org.apache.ibatis.binding.MapperProxy.invoke(MapperProxy.java:86) ~[mybatis-3.5.9.jar:3.5.9]
at com.sun.proxy.$Proxy81.insertSelective(Unknown Source) ~[na:na]
at com.inkyi.system.service.SysLogService.insertOperlog(SysLogService.java:21) ~[main/:na]
at com.inkyi.framework.manager.AsyncFactory$1.run(AsyncFactory.java:88) ~[main/:na]
at java.base/java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:515) ~[na:na]
at java.base/java.util.concurrent.FutureTask.run$$$capture(FutureTask.java:264) ~[na:na]
at java.base/java.util.concurrent.FutureTask.run(FutureTask.java) ~[na:na]
at java.base/java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.run(ScheduledThreadPoolExecutor.java:304) ~[na:na]
at java.base/java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1128) ~[na:na]
at java.base/java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:628) ~[na:na]
at java.base/java.lang.Thread.run(Thread.java:834) ~[na:na]
The project modules are as follows:
Mapper.XML and mapper classes are 100% sure.
That’s the configuration problem. Check to scan mapper in the configuration file XML configuration
#mybatis
mybatis.type-aliases-package=com.inkyi.*.entity
mybatis.mapper-locations=classpath:mapper/*/*.xml
Set
mybatis. mapper-locations=classpath:mapper/*/*. xml
Change to
mybatis. mapper-locations=classpath*:mapper/*/*. xml
Classpath: only the class directory under this project will be scanned
Classpath *: class directory in jar package will be scanned