Run spring boot with jdk9 using jigsaw modules

后端 未结 4 1951
予麋鹿
予麋鹿 2020-12-18 03:57

What\'s wrong with this application. I thought the mix of classpath jars and module jars are valid. For all jars not having an explicit module-info become an automatic modul

4条回答
  •  清歌不尽
    2020-12-18 04:46

    finally, I got it... my module-info have to look like this:

    module test {
        requires java.sql; // my real problem solved with this
        requires spring.boot.autoconfigure;
        requires spring.boot;
        exports com.foo.test; // subsequent error 1: beeing accessible for some spring modules
        opens com.foo.test to spring.core; // subsequent error 2: beeing accessible for spring.core in a deep reflection way
    }
    

    Can someone explain why I have to requires java.sql; inside my own module when I don't use it?

提交回复
热议问题