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

Update target platform #382

Closed
wants to merge 1 commit into from

Conversation

merks
Copy link
Contributor

@merks merks commented Aug 6, 2024

  • Update docker-client to 8.0.1 which requires jakarta.ws.rs-api 4.0.0.

- Update docker-client to 8.0.1 which requires jakarta.ws.rs-api 4.0.0.
@merks
Copy link
Contributor Author

merks commented Aug 6, 2024

@akurtakov

Note that there are two versions of jakarta.ws.rs-api because without the older version the build fails like this:

[ERROR] Cannot resolve dependencies of project org.eclipse.linuxtools:org.eclipse.linuxtools.docker.core:eclipse-plugin:5.16.0-SNAPSHOT
[ERROR]  with context {osgi.os=linux, osgi.ws=gtk, org.eclipse.update.install.features=true, osgi.arch=x86_64, org.eclipse.update.install.sources=true}
[ERROR]   Software being installed: org.eclipse.linuxtools.docker.core 5.16.0.qualifier
[ERROR]   Missing requirement: org.glassfish.jersey.connectors.jersey-apache-connector 3.1.8 requires 'java.package; jakarta.ws.rs [3.1.0,4.0.0)' but it could not be found
[ERROR]   Cannot satisfy dependency: org.eclipse.linuxtools.docker.core 5.16.0.qualifier depends on: java.package; org.glassfish.jersey.apache.connector 0.0.0: See log for details

@akurtakov
Copy link
Contributor

@jjohnstn Would you please test/verify this one? Mixing differeng rs-api impl gives me bad feelings.

@jjohnstn
Copy link
Contributor

jjohnstn commented Aug 6, 2024

@akurtakov Will do.

@jjohnstn
Copy link
Contributor

jjohnstn commented Aug 6, 2024

@merks @akurtakov I tried it out and unfortunately the two packages cause problem with Docker Tooling:

eclipse.buildId=4.33.0.20240801-0745
java.version=21.0.4
java.vendor=Eclipse Adoptium
BootLoader constants: OS=linux, ARCH=x86_64, WS=gtk, NL=en_US
Framework arguments: -product org.eclipse.epp.package.cpp.product
Command-line arguments: -os linux -ws gtk -arch x86_64 -product org.eclipse.epp.package.cpp.product -data /home/jjohnstn/workspace-cpp-2024-09-m2 -data file:/home/jjohnstn/workspace-cpp-2024-09-m2/

org.eclipse.linuxtools.docker.ui
Error
Tue Aug 06 14:59:55 EDT 2024
FrameworkEvent ERROR

org.osgi.framework.BundleException: Could not resolve module: org.eclipse.linuxtools.docker.ui [669]
Unresolved requirement: Require-Bundle: org.eclipse.linuxtools.docker.core; bundle-version="1.0.0"
-> Bundle-SymbolicName: org.eclipse.linuxtools.docker.core; bundle-version="5.16.0.202408061822"; singleton:="true"
org.eclipse.linuxtools.docker.core [666]
No resolution report for the bundle. Bundle was not resolved because of a uses constraint violation.
org.apache.felix.resolver.reason.ReasonException: Uses constraint violation. Unable to resolve resource org.eclipse.linuxtools.docker.core [osgi.identity; type="osgi.bundle"; version:Version="5.16.0.202408061822"; osgi.identity="org.eclipse.linuxtools.docker.core"; singleton:="true"] because it is exposed to package 'jakarta.ws.rs' from resources jakarta.ws.rs-api [osgi.identity; type="osgi.bundle"; version:Version="4.0.0"; osgi.identity="jakarta.ws.rs-api"] and jakarta.ws.rs-api [osgi.identity; type="osgi.bundle"; version:Version="3.1.0"; osgi.identity="jakarta.ws.rs-api"] via two dependency chains.

Chain 1:
org.eclipse.linuxtools.docker.core [osgi.identity; type="osgi.bundle"; version:Version="5.16.0.202408061822"; osgi.identity="org.eclipse.linuxtools.docker.core"; singleton:="true"]
import: (&(osgi.wiring.package=jakarta.ws.rs)(version>=2.0.1))
|
export: osgi.wiring.package: jakarta.ws.rs
jakarta.ws.rs-api [osgi.identity; type="osgi.bundle"; version:Version="4.0.0"; osgi.identity="jakarta.ws.rs-api"]

Chain 2:
org.eclipse.linuxtools.docker.core [osgi.identity; type="osgi.bundle"; version:Version="5.16.0.202408061822"; osgi.identity="org.eclipse.linuxtools.docker.core"; singleton:="true"]
import: (osgi.wiring.package=org.glassfish.jersey.apache.connector)
|
export: osgi.wiring.package=org.glassfish.jersey.apache.connector; uses:=jakarta.ws.rs.client
org.glassfish.jersey.connectors.jersey-apache-connector [osgi.identity; type="osgi.bundle"; version:Version="3.1.8"; osgi.identity="org.glassfish.jersey.connectors.jersey-apache-connector"]
import: (&(osgi.wiring.package=jakarta.ws.rs.client)(&(version>=3.1.0)(!(version>=4.0.0))))
|
export: osgi.wiring.package: jakarta.ws.rs.client; uses:=jakarta.ws.rs
export: osgi.wiring.package=jakarta.ws.rs
jakarta.ws.rs-api [osgi.identity; type="osgi.bundle"; version:Version="3.1.0"; osgi.identity="jakarta.ws.rs-api"]
at org.eclipse.osgi.container.Module.start(Module.java:493)
at org.eclipse.osgi.container.ModuleContainer$ContainerStartLevel$2.run(ModuleContainer.java:2074)
at org.eclipse.osgi.internal.framework.EquinoxContainerAdaptor$1$1.execute(EquinoxContainerAdaptor.java:143)
at org.eclipse.osgi.container.ModuleContainer$ContainerStartLevel.incStartLevel(ModuleContainer.java:2065)
at org.eclipse.osgi.container.ModuleContainer$ContainerStartLevel.incStartLevel(ModuleContainer.java:2005)
at org.eclipse.osgi.container.ModuleContainer$ContainerStartLevel.doContainerStartLevel(ModuleContainer.java:1968)
at org.eclipse.osgi.container.ModuleContainer$ContainerStartLevel.dispatchEvent(ModuleContainer.java:1884)
at org.eclipse.osgi.container.ModuleContainer$ContainerStartLevel.dispatchEvent(ModuleContainer.java:1)
at org.eclipse.osgi.framework.eventmgr.EventManager.dispatchEvent(EventManager.java:230)
at org.eclipse.osgi.framework.eventmgr.EventManager$EventThread.run(EventManager.java:341)

@merks
Copy link
Contributor Author

merks commented Aug 6, 2024

Thanks @jjohnstn!

So this will only work when org.glassfish.jersey.connectors.jersey-apache-connector has a version that works also with a newer version of jakarta.ws.rs-api. As such, this is an experiment gone wrong. I'm surprised that tests didn't fail. I'll close this and will keep an eye out for newer versions of org.glassfish.jersey.connectors.jersey-apache-connector.

@merks merks closed this Aug 6, 2024
@merks merks deleted the pr-docker-8.0.1 branch August 6, 2024 19:26
@jjohnstn
Copy link
Contributor

@merks FWIW: I opened a bug against docker-client and they reduced the rs-api requirement and did an 8.0.2. I have updated Linux Tools to 8.0.2 just now and it will be in M3.

@merks
Copy link
Contributor Author

merks commented Aug 17, 2024

@jjohnstn Thanks for the heads up. 😀

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

Successfully merging this pull request may close these issues.

3 participants