Skip to content

Commit fdfccb2

Browse files
committed
A Java 21 Execution Environment is required at a minimum.
- Eclipse Platform 4.35 now requires Java 21 - Remove unnecessary Jenkinsfile (builds occur on Github Actions) Signed-off-by: Roland Grunberg <[email protected]>
1 parent 266537c commit fdfccb2

File tree

8 files changed

+16
-176
lines changed

8 files changed

+16
-176
lines changed

.github/workflows/pr-verify.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@ jobs:
1818
- name: Set Up Java
1919
uses: actions/setup-java@v4
2020
with:
21-
java-version: '17'
21+
java-version: '21'
2222
distribution: 'adopt'
2323
- run: npm install -g typescript "vsce"
2424
- run: wget http://download.eclipse.org/jdtls/snapshots/jdt-language-server-latest.tar.gz

.github/workflows/release.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -135,7 +135,7 @@ jobs:
135135
run: |
136136
platforms=("win32-x64" "linux-x64" "linux-arm64" "darwin-x64" "darwin-arm64")
137137
for platform in ${platforms[@]}; do
138-
npx gulp download_jre --target ${platform} --javaVersion 17
138+
npx gulp download_jre --target ${platform} --javaVersion 21
139139
vsce package ${{ env.publishPreReleaseFlag }} --target ${platform} -o java-${platform}-${{ env.EXT_VERSION }}-${GITHUB_RUN_NUMBER}.vsix
140140
done
141141
rm -rf jre/

.sdkmanrc

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,3 @@
11
# Enable auto-env through the sdkman_auto_env config
22
# Add key=value pairs of SDKs to use below
3-
java=17.0.3-tem
3+
java=21.0.5-tem

Jenkinsfile

Lines changed: 0 additions & 160 deletions
This file was deleted.

README.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@ Quick Start
1515
============
1616
1. Install the Extension
1717
2. On the following platforms, the extension should activate without any setup : `win32-x64`, `darwin-x64`, `darwin-arm64`, `linux-x64`, `linux-arm64`.\
18-
If on another platform, or using the "universal" version, you can [set](#setting-the-jdk) a _Java_ Development Kit. It must be Java 17 or above.
18+
If on another platform, or using the "universal" version, you can [set](#setting-the-jdk) a _Java_ Development Kit. It must be Java 21 or above.
1919
3. Optionally, download and install a Java Development Kit for your project (Java 1.8 or above is supported). See [Project JDKs](#project-jdks) for more details
2020
4. Extension is activated when you first access a Java file
2121
* Recognizes projects with *Maven* or *Gradle* build files in the directory hierarchy.
@@ -60,7 +60,7 @@ Now that Java extension will publish platform specific versions, it will embed a
6060

6161
The following part is only kept for the universal version without embedded JRE.
6262

63-
>The tooling JDK will be used to launch the Language Server for Java. And by default, will also be used to compile your projects. Java 17 is the minimum required version.\
63+
>The tooling JDK will be used to launch the Language Server for Java. And by default, will also be used to compile your projects. Java 21 is the minimum required version.\
6464
\
6565
The path to the Java Development Kit can be specified by the `java.jdt.ls.java.home` setting in VS Code settings (workspace/user settings). If not specified, it is searched in the following order until a JDK meets current minimum requirement.
6666
>- the `JDK_HOME` environment variable

gulpfile.js

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -29,12 +29,12 @@ gulp.task('clean_jre', function (done) {
2929
});
3030

3131
// Pls update the latest JRE if a new JDK is announced.
32-
const LATEST_JRE = 17;
32+
const LATEST_JRE = 21;
3333

3434
/**
3535
* Usage:
3636
* npx gulp download_jre // Download the latest JRE for the platform of the current running machine.
37-
* npx gulp download_jre --target darwin-x64 --javaVersion 17 // Download the specified JRE for the specified platform.
37+
* npx gulp download_jre --target darwin-x64 --javaVersion 21 // Download the specified JRE for the specified platform.
3838
*
3939
* Supported platforms:
4040
* win32-x64,
@@ -80,11 +80,11 @@ gulp.task('download_jre', async function (done) {
8080

8181
/**
8282
* Here are the contents for a sample justj.manifest file:
83-
* ../20211012_0921/org.eclipse.justj.openjdk.hotspot.jre.full.stripped-17-linux-aarch64.tar.gz
84-
* ../20211012_0921/org.eclipse.justj.openjdk.hotspot.jre.full.stripped-17-linux-x86_64.tar.gz
85-
* ../20211012_0921/org.eclipse.justj.openjdk.hotspot.jre.full.stripped-17-macosx-aarch64.tar.gz
86-
* ../20211012_0921/org.eclipse.justj.openjdk.hotspot.jre.full.stripped-17-macosx-x86_64.tar.gz
87-
* ../20211012_0921/org.eclipse.justj.openjdk.hotspot.jre.full.stripped-17-win32-x86_64.tar.gz
83+
* ../20241101_1100/org.eclipse.justj.openjdk.hotspot.jre.full.stripped-21.0.5-linux-aarch64.tar.gz
84+
* ../20241101_1100/org.eclipse.justj.openjdk.hotspot.jre.full.stripped-21.0.5-linux-x86_64.tar.gz
85+
* ../20241101_1100/org.eclipse.justj.openjdk.hotspot.jre.full.stripped-21.0.5-macosx-aarch64.tar.gz
86+
* ../20241101_1100/org.eclipse.justj.openjdk.hotspot.jre.full.stripped-21.0.5-macosx-x86_64.tar.gz
87+
* ../20241101_1100/org.eclipse.justj.openjdk.hotspot.jre.full.stripped-21.0.5-win32-x86_64.tar.gz
8888
*/
8989
const javaPlatform = platformMapping[targetPlatform];
9090
const list = manifest.split(/\r?\n/);

package.json

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -311,7 +311,7 @@
311311
"null"
312312
],
313313
"default": null,
314-
"description": "Specifies the folder path to the JDK (17 or more recent) used to launch the Java Language Server.\nOn Windows, backslashes must be escaped, i.e.\n\"java.home\":\"C:\\\\Program Files\\\\Java\\\\jdk-17.0_3\"",
314+
"description": "Specifies the folder path to the JDK (21 or more recent) used to launch the Java Language Server.\nOn Windows, backslashes must be escaped, i.e.\n\"java.home\":\"C:\\\\Program Files\\\\Java\\\\jdk-21.0_5\"",
315315
"scope": "machine-overridable",
316316
"deprecationMessage": "This setting is deprecated, please use 'java.jdt.ls.java.home' instead.",
317317
"order": 0
@@ -322,7 +322,7 @@
322322
"null"
323323
],
324324
"default": null,
325-
"description": "Specifies the folder path to the JDK (17 or more recent) used to launch the Java Language Server. This setting will replace the Java extension's embedded JRE to start the Java Language Server. \n\nOn Windows, backslashes must be escaped, i.e.\n\"java.jdt.ls.java.home\":\"C:\\\\Program Files\\\\Java\\\\jdk-17.0_3\"",
325+
"description": "Specifies the folder path to the JDK (21 or more recent) used to launch the Java Language Server. This setting will replace the Java extension's embedded JRE to start the Java Language Server. \n\nOn Windows, backslashes must be escaped, i.e.\n\"java.jdt.ls.java.home\":\"C:\\\\Program Files\\\\Java\\\\jdk-21.0_5\"",
326326
"scope": "machine-overridable",
327327
"order": 10
328328
},

src/requirements.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -41,7 +41,7 @@ export async function resolveRequirements(context: ExtensionContext): Promise<Re
4141
const preferenceName = javaPreferences.preference;
4242
let javaHome = javaPreferences.javaHome;
4343
let javaVersion: number = 0;
44-
const REQUIRED_JDK_VERSION = ('on' === getJavaConfiguration().get('jdt.ls.javac.enabled'))?23:17;
44+
const REQUIRED_JDK_VERSION = ('on' === getJavaConfiguration().get('jdt.ls.javac.enabled'))?23:21;
4545
if (javaHome) {
4646
const source = `${preferenceName} variable defined in ${env.appName} settings`;
4747
javaHome = expandHomeDir(javaHome);
@@ -217,4 +217,4 @@ async function getMajorVersion(javaHome: string): Promise<number> {
217217
}
218218
const runtime = await getRuntime(javaHome, { withVersion: true });
219219
return runtime?.version?.major || 0;
220-
}
220+
}

0 commit comments

Comments
 (0)