From 642f045d8e5f4d855cb9b6bf2009b616a728cc13 Mon Sep 17 00:00:00 2001 From: Edward Mezarina Date: Wed, 10 Jul 2024 07:34:26 -0400 Subject: [PATCH] Updates to support Eclipse 2024-06 --- .github/workflows/run-regression-tests.yml | 2 +- .../META-INF/MANIFEST.MF | 2 +- .../META-INF/MANIFEST.MF | 2 +- .../META-INF/MANIFEST.MF | 2 +- ci/jenkins/release | 2 +- ci/jenkins/run-tests | 2 +- ci/scans/dependency-only-mend-pom.xml | 48 +++---- docs/user-guide.md | 11 +- pom.xml | 8 +- .../io.openliberty.tools.update/category.xml | 3 +- .../target-platform-3Q2024.target | 127 ++++++++++++++++++ tests/META-INF/MANIFEST.MF | 2 +- tests/pom.xml | 12 +- .../liberty-gradle-test-app/build.gradle | 12 +- .../build.gradle | 12 +- .../gradle/wrapper/gradle-wrapper.properties | 2 +- .../maven/liberty-maven-test-app/pom.xml | 11 +- .../liberty-maven-test-wrapper-app/pom.xml | 11 +- .../maven-multi-module/typeJ/jar/pom.xml | 18 ++- .../maven/maven-multi-module/typeJ/pom.xml | 14 +- .../maven-multi-module/typeJ/pom/pom.xml | 16 ++- .../maven-multi-module/typeJ/war1/pom.xml | 18 ++- .../maven-multi-module/typeJ/war2/pom.xml | 18 ++- .../maven/non-dflt-server-xml-path/pom.xml | 11 +- .../applications/maven/shared-lib/pom.xml | 18 ++- tests/resources/ci/scripts/setup.sh | 49 ++++--- .../it/AbstractLibertyPluginSWTBotTest.java | 13 +- 27 files changed, 347 insertions(+), 99 deletions(-) create mode 100644 releng/target-platform-3Q-2024/target-platform-3Q2024.target diff --git a/.github/workflows/run-regression-tests.yml b/.github/workflows/run-regression-tests.yml index 6738e29c..8b7fc7ee 100644 --- a/.github/workflows/run-regression-tests.yml +++ b/.github/workflows/run-regression-tests.yml @@ -10,7 +10,7 @@ jobs: fail-fast: false matrix: runtime: [ linux, mac, windows ] - targetPlatform: [ 1Q2024 ] + targetPlatform: [ 3Q2024 ] include: - runtime: linux os: ubuntu-latest diff --git a/bundles/io.openliberty.tools.eclipse.lsp4e/META-INF/MANIFEST.MF b/bundles/io.openliberty.tools.eclipse.lsp4e/META-INF/MANIFEST.MF index a9de83b2..3cb123a5 100644 --- a/bundles/io.openliberty.tools.eclipse.lsp4e/META-INF/MANIFEST.MF +++ b/bundles/io.openliberty.tools.eclipse.lsp4e/META-INF/MANIFEST.MF @@ -8,7 +8,7 @@ Bundle-Version: 24.0.6.qualifier Bundle-Activator: io.openliberty.tools.eclipse.ls.plugin.LibertyToolsLSPlugin Bundle-ActivationPolicy: lazy Automatic-Module-Name: io.openliberty.tools.eclipse.lsp4e -Bundle-RequiredExecutionEnvironment: JavaSE-17 +Bundle-RequiredExecutionEnvironment: JavaSE-21 Require-Bundle: com.google.gson, org.eclipse.lsp4mp.jdt.core, org.eclipse.lsp4jakarta.jdt.core, diff --git a/bundles/io.openliberty.tools.eclipse.product/META-INF/MANIFEST.MF b/bundles/io.openliberty.tools.eclipse.product/META-INF/MANIFEST.MF index 8f37214b..e31799a1 100644 --- a/bundles/io.openliberty.tools.eclipse.product/META-INF/MANIFEST.MF +++ b/bundles/io.openliberty.tools.eclipse.product/META-INF/MANIFEST.MF @@ -5,6 +5,6 @@ Bundle-Name: Liberty Tools Bundle-Vendor: Open Liberty Bundle-SymbolicName: io.openliberty.tools.eclipse.product;singleton:=true Bundle-Version: 24.0.6.qualifier -Bundle-RequiredExecutionEnvironment: JavaSE-17 +Bundle-RequiredExecutionEnvironment: JavaSE-21 Automatic-Module-Name: io.openliberty.tools.eclipse Bundle-ActivationPolicy: lazy diff --git a/bundles/io.openliberty.tools.eclipse.ui/META-INF/MANIFEST.MF b/bundles/io.openliberty.tools.eclipse.ui/META-INF/MANIFEST.MF index 3a104c9f..d830de2a 100644 --- a/bundles/io.openliberty.tools.eclipse.ui/META-INF/MANIFEST.MF +++ b/bundles/io.openliberty.tools.eclipse.ui/META-INF/MANIFEST.MF @@ -14,7 +14,7 @@ Export-Package: io.openliberty.tools.eclipse;x-friends:="io.openliberty.tools.ec io.openliberty.tools.eclipse.ui.preferences;x-friends:="io.openliberty.tools.eclipse.tests" Require-Bundle: org.eclipse.ui, org.eclipse.m2e.maven.runtime -Bundle-RequiredExecutionEnvironment: JavaSE-17 +Bundle-RequiredExecutionEnvironment: JavaSE-21 Automatic-Module-Name: io.openliberty.tools.eclipse.ui Bundle-ActivationPolicy: lazy Import-Package: org.eclipse.cdt.launch.ui, diff --git a/ci/jenkins/release b/ci/jenkins/release index 7a30f3a6..a78a2aef 100644 --- a/ci/jenkins/release +++ b/ci/jenkins/release @@ -2,7 +2,7 @@ pipeline { agent any tools { - jdk 'java17-semeru' + jdk 'jdk-semeru-21.0.3' maven 'maven-3.9.6' } diff --git a/ci/jenkins/run-tests b/ci/jenkins/run-tests index 1a2e333b..57db5617 100644 --- a/ci/jenkins/run-tests +++ b/ci/jenkins/run-tests @@ -2,7 +2,7 @@ pipeline { agent any tools { - jdk 'java17-semeru' + jdk 'jdk-semeru-21.0.3' xvfb 'gui-test' maven 'maven-3.9.6' gradle 'gradle-7.6.1' diff --git a/ci/scans/dependency-only-mend-pom.xml b/ci/scans/dependency-only-mend-pom.xml index 32cbb5ff..c59061d0 100644 --- a/ci/scans/dependency-only-mend-pom.xml +++ b/ci/scans/dependency-only-mend-pom.xml @@ -1,6 +1,6 @@ + com.google.code.gson @@ -117,12 +117,12 @@ OTHER REFERENCES: https://projects.eclipse.org/projects/eclipse.platform/develo org.eclipse.jdt org.eclipse.jdt - 3.19.300 + 3.19.400 org.eclipse.jdt org.eclipse.jdt.core - 3.36.0 + 3.37.0 org.eclipse.jdt @@ -132,105 +132,105 @@ OTHER REFERENCES: https://projects.eclipse.org/projects/eclipse.platform/develo org.eclipse.jdt org.eclipse.jdt.debug.ui - 3.13.200 + 3.13.300 org.eclipse.jdt org.eclipse.jdt.launching - 3.21.0 + 3.21.100 org.eclipse.jdt org.eclipse.jdt.ui - 3.31.0 + 3.32.0 org.eclipse.platform org.eclipse.jface.text - 3.24.200 + 3.25.0 org.eclipse.lsp4j org.eclipse.lsp4j - 0.21.1 + 0.22.0 org.eclipse.lsp4j org.eclipse.lsp4j.jsonrpc - 0.21.1 + 0.22.0 org.eclipse.platform org.eclipse.core.commands - 3.11.200 + 3.12.0 org.eclipse.platform org.eclipse.core.expressions - 3.9.200 + 3.9.300 org.eclipse.platform org.eclipse.core.jobs - 3.15.100 + 3.15.200 org.eclipse.platform org.eclipse.core.resources - 3.20.0 + 3.20.100 org.eclipse.platform org.eclipse.core.runtime - 3.30.0 + 3.31.0 org.eclipse.platform org.eclipse.debug.core - 3.21.200 + 3.21.300 org.eclipse.platform org.eclipse.debug.ui - 3.18.200 + 3.18.300 org.eclipse.platform org.eclipse.equinox.preferences - 3.10.400 + 3.11.0 org.eclipse.platform org.eclipse.osgi - 3.18.600 + 3.19.0 org.eclipse.platform org.eclipse.swt - 3.124.200 + 3.125.0 org.eclipse.platform org.eclipse.ui - 3.205.0 + 3.205.100 org.eclipse.platform org.eclipse.ui.ide - 3.22.0 + 3.22.100 org.eclipse.platform org.eclipse.ui.editors - 3.17.100 + 3.17.200 org.eclipse.platform org.eclipse.ui.workbench - 3.131.0 + 3.131.100 diff --git a/docs/user-guide.md b/docs/user-guide.md index 0bb0be21..21414216 100644 --- a/docs/user-guide.md +++ b/docs/user-guide.md @@ -12,7 +12,7 @@ This guide provides detailed instructions on how to use Liberty Tools for the Ec * [Accessing Liberty Tools Operations](#accessing-liberty-tools-operations) + [Using the Liberty dashboard view](#using-the-liberty-dashboard-view) + [Using the Project Explorer view](#using-the-project-explorer-view) - * [Running your application on Liberty using dev mode](#running-your-application-on-liberty-using-dev-mode-1) + * [Running your application on Liberty using dev mode](#running-your-application-on-liberty-using-dev-mode) + [Start](#start) + [Start with Configuration](#start-with-configuration) + [Start in container](#start-in-container) @@ -46,11 +46,12 @@ This guide provides detailed instructions on how to use Liberty Tools for the Ec | 23.0.12 | 2023-09 - Eclipse v4.29 | | 24.0.3 | 2023-12 - Eclipse v4.30 | | 24.0.6 | 2024-03 - Eclipse v4.31 | +| 24.0.9 | 2024-06 - Eclipse v4.32 | **NOTE:** Tested with each of the `Eclipse IDE for Enterprise Java and Web Developers` and `Eclipse IDE for Java Developers` packages -2. **Java:** The Eclipse IDE itself requires Java 17. However, the application runtime [can be run with other versions of Java](#start-with-configuration), as long as they are supported by Liberty. +2. **Java:** The Eclipse IDE itself requires Java 21. However, the application runtime [can be run with other versions of Java](#start-with-configuration), as long as they are supported by Liberty. 3. [**Liberty Tools**](installation.md) @@ -64,7 +65,7 @@ This guide provides detailed instructions on how to use Liberty Tools for the Ec - Liberty Maven Plugin -> 3.7.1 - - Liberty Gradle Plugin -> 3.5.1 + - Liberty Gradle Plugin -> 3.8 ### Maven and Gradle @@ -83,7 +84,7 @@ Since Liberty dev mode uses the Liberty Maven or Gradle plugins to manage a Mave - Set the Maven/Gradle installation to use. - click on **Apply and Close** to save your changes. -3. If a Maven/Gradle installation is still not found, Liberty Tools looks at the PATH environment variable for install locations. See the instructions in [the following section](#Docker) which can also apply to finding Maven or Gradle executables. +3. If a Maven/Gradle installation is still not found, Liberty Tools looks at the PATH environment variable for install locations. See the instructions in [the following section](#docker) which can also apply to finding Maven or Gradle executables. ### Docker @@ -310,7 +311,7 @@ The Gradle Eclipse plugins (Buildship) run a simple Gradle build upon import (** If this build does not complete successfully, the Liberty Tools function might not work correctly. -For example, if your project uses a Gradle wrapper at a Gradle version less than v7.3, it does not support Java 17 per [matrix](https://docs.gradle.org/current/userguide/compatibility.html), but the Java 17+ workspace JRE is required for running Liberty Tools. +For example, if your project uses a Gradle wrapper at a Gradle version less than v8.4, it does not support Java 21 per [matrix](https://docs.gradle.org/current/userguide/compatibility.html), but the Java 21+ workspace JRE is required for running Liberty Tools. One approach to resolve this incompatibility is to configure the preference at: **Preferences -> Gradle -> Java home** to refer to a Java installation that is compatible with the level of Gradle in your `gradlew` wrapper. diff --git a/pom.xml b/pom.xml index b3f937c8..e9dcf851 100644 --- a/pom.xml +++ b/pom.xml @@ -1,6 +1,6 @@ - 1Q2024 + 3Q2024 @@ -109,7 +109,7 @@ tycho-compiler-plugin ${tycho.version} - 17 + 21 @@ -191,7 +191,7 @@ target-platform-configuration ${tycho.version} - JavaSE-17 + JavaSE-21 io.openliberty.tools.eclipse diff --git a/releng/io.openliberty.tools.update/category.xml b/releng/io.openliberty.tools.update/category.xml index 7d8cfaaa..2f505818 100644 --- a/releng/io.openliberty.tools.update/category.xml +++ b/releng/io.openliberty.tools.update/category.xml @@ -1,6 +1,6 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + net.bytebuddy + byte-buddy-agent + 1.14.18 + jar + + + net.bytebuddy + byte-buddy + 1.14.18 + jar + + + org.mockito + mockito-core + 5.12.0 + jar + + + org.mockito + mockito-junit-jupiter + 5.12.0 + jar + + + org.objenesis + objenesis + 3.4 + jar + + + + + diff --git a/tests/META-INF/MANIFEST.MF b/tests/META-INF/MANIFEST.MF index dce83113..94ad1217 100644 --- a/tests/META-INF/MANIFEST.MF +++ b/tests/META-INF/MANIFEST.MF @@ -4,7 +4,7 @@ Bundle-ManifestVersion: 2 Bundle-Name: Tests Plug-in Bundle-SymbolicName: io.openliberty.tools.eclipse.tests Bundle-Version: 24.0.6.qualifier -Bundle-RequiredExecutionEnvironment: JavaSE-17 +Bundle-RequiredExecutionEnvironment: JavaSE-21 Require-Bundle: junit-jupiter-api;bundle-version="[5.8.0,6.0.0)", org.eclipse.ui, org.hamcrest.library;bundle-version="[1.3.0,2.2)" diff --git a/tests/pom.xml b/tests/pom.xml index 5f4127b7..8eb27fa1 100755 --- a/tests/pom.xml +++ b/tests/pom.xml @@ -1,6 +1,6 @@ + + -XstartOnFirstThread + -Dnet.bytebuddy.experimental=true + alphabetical diff --git a/tests/resources/applications/gradle/liberty-gradle-test-app/build.gradle b/tests/resources/applications/gradle/liberty-gradle-test-app/build.gradle index 6bb55d97..7a402bd4 100644 --- a/tests/resources/applications/gradle/liberty-gradle-test-app/build.gradle +++ b/tests/resources/applications/gradle/liberty-gradle-test-app/build.gradle @@ -4,19 +4,25 @@ apply plugin: 'war' version '0.0.1-SNAPSHOT' group 'liberty.gradle.test.app' -sourceCompatibility = 11 -targetCompatibility = 11 +sourceCompatibility = 21 +targetCompatibility = 21 tasks.withType(JavaCompile) { options.encoding = 'UTF-8' } +java { + toolchain { + languageVersion = JavaLanguageVersion.of(21) + } +} + buildscript { repositories { mavenCentral() mavenLocal() } dependencies { - classpath 'io.openliberty.tools:liberty-gradle-plugin:3.6.2' + classpath 'io.openliberty.tools:liberty-gradle-plugin:3.8.3' } } diff --git a/tests/resources/applications/gradle/liberty-gradle-test-wrapper-app/build.gradle b/tests/resources/applications/gradle/liberty-gradle-test-wrapper-app/build.gradle index 023a636e..def28cac 100644 --- a/tests/resources/applications/gradle/liberty-gradle-test-wrapper-app/build.gradle +++ b/tests/resources/applications/gradle/liberty-gradle-test-wrapper-app/build.gradle @@ -4,18 +4,24 @@ apply plugin: 'war' version '0.0.1-SNAPSHOT' group 'liberty.gradle.test.app' -sourceCompatibility = 11 -targetCompatibility = 11 +sourceCompatibility = 21 +targetCompatibility = 21 tasks.withType(JavaCompile) { options.encoding = 'UTF-8' } +java { + toolchain { + languageVersion = JavaLanguageVersion.of(21) + } +} + buildscript { repositories { mavenCentral() } dependencies { - classpath 'io.openliberty.tools:liberty-gradle-plugin:3.6.2' + classpath 'io.openliberty.tools:liberty-gradle-plugin:3.8.3' } } diff --git a/tests/resources/applications/gradle/liberty-gradle-test-wrapper-app/gradle/wrapper/gradle-wrapper.properties b/tests/resources/applications/gradle/liberty-gradle-test-wrapper-app/gradle/wrapper/gradle-wrapper.properties index aa991fce..0d184210 100644 --- a/tests/resources/applications/gradle/liberty-gradle-test-wrapper-app/gradle/wrapper/gradle-wrapper.properties +++ b/tests/resources/applications/gradle/liberty-gradle-test-wrapper-app/gradle/wrapper/gradle-wrapper.properties @@ -1,5 +1,5 @@ distributionBase=GRADLE_USER_HOME distributionPath=wrapper/dists -distributionUrl=https\://services.gradle.org/distributions/gradle-7.4.2-bin.zip +distributionUrl=https\://services.gradle.org/distributions/gradle-8.8-bin.zip zipStoreBase=GRADLE_USER_HOME zipStorePath=wrapper/dists diff --git a/tests/resources/applications/maven/liberty-maven-test-app/pom.xml b/tests/resources/applications/maven/liberty-maven-test-app/pom.xml index 3405976d..c448725a 100644 --- a/tests/resources/applications/maven/liberty-maven-test-app/pom.xml +++ b/tests/resources/applications/maven/liberty-maven-test-app/pom.xml @@ -1,6 +1,6 @@ + xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 + http://maven.apache.org/xsd/maven-4.0.0.xsd"> 4.0.0 test liberty.maven.test.app @@ -23,8 +24,8 @@ UTF-8 UTF-8 - 11 - 11 + 21 + 21 minify,runnable @@ -70,7 +71,7 @@ io.openliberty.tools liberty-maven-plugin - 3.7.1 + 3.10.3 120 true diff --git a/tests/resources/applications/maven/liberty-maven-test-wrapper-app/pom.xml b/tests/resources/applications/maven/liberty-maven-test-wrapper-app/pom.xml index 1781410f..c48e625d 100644 --- a/tests/resources/applications/maven/liberty-maven-test-wrapper-app/pom.xml +++ b/tests/resources/applications/maven/liberty-maven-test-wrapper-app/pom.xml @@ -1,6 +1,6 @@ + xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 + http://maven.apache.org/xsd/maven-4.0.0.xsd"> 4.0.0 test liberty.maven.test.wrapper.app @@ -23,8 +24,8 @@ UTF-8 UTF-8 - 17 - 17 + 21 + 21 minify,runnable @@ -63,7 +64,7 @@ io.openliberty.tools liberty-maven-plugin - 3.7.1 + 3.10.3 120 true diff --git a/tests/resources/applications/maven/maven-multi-module/typeJ/jar/pom.xml b/tests/resources/applications/maven/maven-multi-module/typeJ/jar/pom.xml index 9085c5cc..3dcd6032 100644 --- a/tests/resources/applications/maven/maven-multi-module/typeJ/jar/pom.xml +++ b/tests/resources/applications/maven/maven-multi-module/typeJ/jar/pom.xml @@ -1,4 +1,16 @@ - + + + + + + + xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 + http://maven.apache.org/xsd/maven-4.0.0.xsd"> 4.0.0 test non.dflt.server.xml.path @@ -23,8 +24,8 @@ UTF-8 UTF-8 - 11 - 11 + 21 + 21 minify,runnable @@ -63,7 +64,7 @@ io.openliberty.tools liberty-maven-plugin - 3.7.1 + 3.10.3 120 src/main/liberty/config/my.xml diff --git a/tests/resources/applications/maven/shared-lib/pom.xml b/tests/resources/applications/maven/shared-lib/pom.xml index 6078669e..81070b14 100644 --- a/tests/resources/applications/maven/shared-lib/pom.xml +++ b/tests/resources/applications/maven/shared-lib/pom.xml @@ -1,4 +1,16 @@ - + + projectsToInstall) t for (File projectFile : projectsToInstall) { IPath projectLocation = org.eclipse.core.runtime.Path .fromOSString(Paths.get(projectFile.getPath()).toAbsolutePath().toString()); - BuildConfiguration configuration = BuildConfiguration.forRootProjectDirectory(projectLocation.toFile()).build(); + BuildConfiguration configuration = BuildConfiguration.forRootProjectDirectory(projectLocation.toFile()) + .gradleDistribution(GradleDistribution.forVersion(BUILDSHIP_GRADLE_DISTRIBUTION)) + .overrideWorkspaceConfiguration(true).build(); GradleWorkspace workspace = GradleCore.getWorkspace(); GradleBuild newBuild = workspace.createBuild(configuration); newBuild.synchronize(new NullProgressMonitor());