[ 
https://issues.apache.org/jira/browse/MCOMPILER-436?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17214854#comment-17214854
 ] 

Gili commented on MCOMPILER-436:
--------------------------------

Hi Robert,

1. It sounds to me like the plugin should be able to extract a module name from 
the JAR file even if later on that module cannot be used due to the split 
package issue. Therefore the first message is misleading and should be 
corrected.
2. Is it really illegal for a Java Module to reference a service contained in 
an external module? Assuming both are legal modules (no split package) this 
should work, right?
3. Can we improve the error message to mention that "although <filename1> can 
be used on the classpath, it cannot be loaded on the module path due to split 
package <name> found in both <filename1> and <filename2>"?

> Cannot compile code that depends on on Apache Mina SSH due to JPMS error
> ------------------------------------------------------------------------
>
>                 Key: MCOMPILER-436
>                 URL: https://issues.apache.org/jira/browse/MCOMPILER-436
>             Project: Maven Compiler Plugin
>          Issue Type: Bug
>    Affects Versions: 3.8.1
>            Reporter: Gili
>            Priority: Major
>         Attachments: extract-module-name.zip
>
>
> 1. Extract Testcase
> 2. Run "mvn clean install"
> 3. Build fails with:
> [WARNING] Can't extract module name from sshd-core-2.5.1.jar: Provider class 
> org.apache.sshd.common.file.root.RootedFileSystemProvider not in module
> [ERROR] module not found: sshd.core
> Expected behavior: The plugin should be able to extract the module name given 
> that sshd-core depends on sshd-commons which contains the aforementioned 
> provider and automatic modules can access classes outside their module.



--
This message was sent by Atlassian Jira
(v8.3.4#803005)

Reply via email to