[
https://issues.apache.org/jira/browse/MCOMPILER-328?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16398365#comment-16398365
]
Robert Scholte commented on MCOMPILER-328:
------------------------------------------
When running this with the implementation of MCOMPILER-321 I see the following
message:
{noformat}
[WARNING] Can't extract module name from the following entries:
- elasticsearch-6.2.2.jar: Provider class
org.apache.lucene.search.suggest.document.Completion50PostingsFormat not in
module
{noformat}
That at least explains why it cannot be found (to be explicit: it uses the JDK
to get the name, no specific Maven code). Because of this the jar is put on the
classpath instead of the modulepath.
I don't know how Gradle compiles, maybe you can figure out the arguments passed
to the compiler.
> Module not found when java services are involved
> ------------------------------------------------
>
> Key: MCOMPILER-328
> URL: https://issues.apache.org/jira/browse/MCOMPILER-328
> Project: Maven Compiler Plugin
> Issue Type: Bug
> Affects Versions: 3.7.0
> Reporter: Réda Housni Alaoui
> Priority: Critical
>
> I have a project using Maven and Java 9 that is unable to require
> elasticsearch automodule.
> I created a a project reproducing easily the issue with a README containing
> all the details:
> [https://github.com/Cosium/jigsaw-elasticsearch]
> Just clone it and run {{mvn clean package}}
> Build fails with:
> {{[ERROR] Failed to execute goal
> org.apache.maven.plugins:maven-compiler-plugin:3.7.0:compile
> (default-compile) on project jigsaw-elasticsearch: Compilation failure
> [ERROR]
> /srv/git/cosium/jigsaw-elasticsearch/src/main/java/module-info.java:[7,14]
> module not found: elasticsearch}}
> The same project compiles well with Gradle.
> Therefore I am inclined to believe the issue comes from Maven.
--
This message was sent by Atlassian JIRA
(v7.6.3#76005)