Has anyone used ServiceLoader together with Guice?

前端 未结 3 1664
既然无缘
既然无缘 2021-01-31 11:41

I keep wanting to try this on a larger scale with our app + build system, but higher priorities keep pushing it to the back burner. It seems like a nice way to load Guice module

3条回答
  •  小鲜肉
    小鲜肉 (楼主)
    2021-01-31 12:11

    I considered this way already but i didnt use it because i was afraid, that i have to keep my modules extremely small, because its impossible to bind the same interface twice. My problem is, that if i want to use an interface/class/enum/whatever from another jar and that jar defined a services/* file i am screwed, because i cant make use of the content of the jar without loading it as a module.

    I hope my concern is clear.

提交回复
热议问题