java 9 module reads package X from A and B

后端 未结 2 1478
终归单人心
终归单人心 2020-12-06 06:16

I am trying to use spring boot with java 9 and gradle. I am unable to run my simple code, I get the below mentioned error :-

Information:java: Errors occurre         


        
2条回答
  •  孤城傲影
    2020-12-06 06:26

    Excluding the transitive dependency made it work and adjusting the module-info.java too!!!

    compile("org.springframework.boot:spring-boot-starter:1.5.3.RELEASE") {
            exclude group: 'commons-logging', module: 'commons-logging'
        }
        compile("org.springframework.boot:spring-boot-starter-web:1.5.3.RELEASE"){
            exclude group: 'commons-logging', module: 'commons-logging'
        }
    

提交回复
热议问题