springboot构建多模块时报 java.lang.ClassNotFoundException: org.mybatis.logging.LoggerFactory

Caused by: java.lang.ClassNotFoundException: org.mybatis.logging.LoggerFactory
    at java.net.URLClassLoader.findClass(URLClassLoader.java:381)
    at java.lang.ClassLoader.loadClass(ClassLoader.java:424)
    at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:331)
    at java.lang.ClassLoader.loadClass(ClassLoader.java:357)
    ... 32 common frames omitted

原因:springboot全局依赖与父类包冲突,其中springboot的版本不一致导致报错

 
    
        
            
            
                org.springframework.boot
                spring-boot-dependencies
                2.1.1.RELEASE
                pom
                import
            
        
    

    org.springframework.boot
    spring-boot-starter-parent
    2.2.2.RELEASE
     

解决:随机去掉一个

你可能感兴趣的:(springboot构建多模块时报 java.lang.ClassNotFoundException: org.mybatis.logging.LoggerFactory)