weld-servlet-core depends on weld-environment-common so you'll have dependencies on both module.
Antoine Sabot-Durand yea, you are right ... Monday morning after PTO can be rough
... Jigsaw doesn't allow 2 modules sharing the same package no matter their visibility.
Not exactly right. Say you have module A and B; now module B requires A. Both have some same package like dummy.test and inside it any classes. The situation now is as follows:
-
If A exports dummy.test
-
e.g. contents of dummy.test should be accessible/visible to module B
-
there is a conflict and you get an error saying that package exists in another module
-
If A does not export dummy.test
-
e.g. contents of the package are not visible to B
-
it works since there is no package 'clash' on the module path
So unless the packages need to be exported, there is no real conflict (not saying there ain't one in Weld case). Whether there is a conflict or not in Weld depends on how well you fine-grain the modularisation. If weld-environments-common becomes one module and weld-servlet-core another one (as only 2 big modules) then there is a conflict. If, however, you made a per-package modules you might avoid that because org.jboss.weld.environment from weld-environment-common is used in differently named packages in weld-servlet-core.
BTW probably the best (and the only reliable?) resource on Jigsaw is State of the module system. Even though it is looong read and requires several coffees.
|