Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

importCommands using globs does not with with Java9 #469

Open
hossman opened this issue Feb 28, 2017 · 0 comments
Open

importCommands using globs does not with with Java9 #469

hossman opened this issue Feb 28, 2017 · 0 comments

Comments

@hossman
Copy link

hossman commented Feb 28, 2017

the "importCommands" parsing code for dealing with prefix based globs (ie: org.kitesdk.** or com.foo.morphlines.*) Doesn't work using Java9.

This seems to be because the underlying classpath scanning is build on the ClassPath.from(ClassLoader) API shadded from Guava, which has a very notable limitation documented...

* <p>Currently only {@link URLClassLoader} and only {@code file://} urls are supported.

...but in Java9, URLClassLoader is (aparently) rarely used as a result of the new (jigsaw) module system.

The only work around seems to be to change all morphlines configs to remove * globs from importCommands declarations and enumate every CommandBuilder implemenation needed for the config.

I suggest morphlines switch to using SPI based scanning for CommandBuilders since that is a good API for plugins that has been supported by the JVM for a looooong time, and continues to work in Java9.

See also: https://issues.apache.org/jira/browse/SOLR-8876

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant