-
Notifications
You must be signed in to change notification settings - Fork 19
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
module path is not working #51
Comments
What version of Java are you using? |
openjdk version "11.0.14.1" 2022-02-08 |
The issue is that Java Module System will only pull in the modules on the module path that are required from the starting module (you specified To add all your modules you need to specify the java option But when I do that I get this:
Note that we are in the process of removing org.osgi.service.cm from the org.eclipse.osgi.services and having it instead require-reexport this org.osgi.service.cm bundle. That may help you in this case. But for now I would avoid trying to use |
The exception you see from equinox is just an annoying |
Well OSGi and JPMS seems to be a bigger issue. :) Anyhow, if I remove the module-info.class from the corresponding jars, it passes my former modules, but then fails with this:
Probably similar to the issue you described above. The Felix setup then works, despite the "modify" command. Probably I forgot to export the package that contains the service implementation. Which is also something I do not fully understand as an OSGi guy. ;)
At least I know understand the issue better. And I will then continue with the Graal/Substrate example. Thanks a lot for the fast response! |
Oh, btw, maybe it would be good to add the hint about the modules to load to the README. Because I simply followed the instructions and started the example the same way as explained there. Could be lead also others to the same issue. |
Good idea, I updated the README with some hint there. |
@rotty3000 has been doing some work recently here. Maybe he has some examples to point you to? |
@fipro78 I pinged you on the OSGi slack if you want to chat about what bnd has been working on in this area. Feel free to reach out. |
With the recommended updates to starting the runtime and the removal of the module-info from my bundles, things are working as expected. As you already updated the README to add the information about adding the modules, this ticket can be closed. |
I am trying to setup a simple example to better understand how Atomos can be used. The example looks similar to the example showed in the README, it just uses the most current versions of Equinox/Felix and I of course had to build Atomos locally, which makes it a 1.0.1-SNAPSHOT. I created setups for Equinox and Felix as the underlying OSGi framework.
Using the classpath variant both examples work fine.
Using the module path variant none of the examples is working.
For Equinox (org.eclipse.osgi-3.17.200.jar) I get the following exception:
For Felix (org.apache.felix.framework-7.0.3.jar) the felix-cache is created, but then nothing happens. The application does actually not start.
I attach the two examples as archive that contain also the start calls in Windows batch files.
atomos_felix.zip
atomos_equinox.zip
The text was updated successfully, but these errors were encountered: