Skip to content

Correctly find and use OpenJDK #8336

@i-make-robots

Description

@i-make-robots

Description

Running netbeans-25 for the first time.
Popup tells me to install java >=17 or use command line --jdkhome.
Run netbeans64.exe --jdkhome C:\users\me.jdks\openjdk22.0.2
Quit and run again. Doesn't remember the JDK I used.

Expected behavior:

  1. find default installs of openjdk
  2. remember alt jdks supplied by user. 2a) at least remember one if there are no others available.

Workaround:
Edit the netbeans shortcut to include the --jdkhome param. Forget all about it until the next openJDK update causes confusion/frustration.

Context:
I have installed:
c:\program files\java\jdk-13
c:\program files\java\jdk-15
c:\program files\java\jdk-15.0.1
c:\program files\java\jdk-15.0.2
c:\program files\java\jre1.8.0_441
c:\users\me.jdks\openjdk-21
c:\users\me.jdks\openjdk-21.0.1
c:\users\me.jdks\openjdk-21.0.2
c:\users\me.jdks\openjdk-22
c:\users\me.jdks\openjdk-22.0.1
c:\users\me.jdks\openjdk-21.0.2

I will be removing most of these. Just odd Netbeans couldn't find a single one over 17.

Use case/motivation

No response

Related issues

No response

Are you willing to submit a pull request?

No

Metadata

Metadata

Assignees

No one assigned

    Labels

    kind:featureA feature requestneeds:triageRequires attention from one of the committers

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions