Skip to content

[BUG] Server powershell startup doesn't accept some Java 17 versions #394

Closed

Description

@eddcomeau

I swear this was working for me earlier and I don't see any changes, so I am wondering if I am missing something here. But I will document in case it is new

Describe the bug

The Windows PowerShell launcher incorrectly rejects a valid Java 17 executable supplied through OIE_JAVA_PATH or JAVA_HOME.

The issue is consistently reproducible when launching the development server with a valid Java 17 installation.

To Reproduce

  1. Open PowerShell.

  2. Navigate to the server setup directory:

    cd %location_of_engine%\engine\server\setup
  3. Set a valid Java 17 executable:

    $env:OIE_JAVA_PATH = 'C:\Program Files\Eclipse Adoptium\jdk-17.0.18.8-hotspot\bin\java.exe'
  4. Run the launcher:

    .\oieserver.ps1
  5. Observe the validation error.

Expected behavior

The launcher should recognize the Java executable as valid and start the Open Integration Engine server.

Actual behavior

The launcher exits with:

'C:\Program Files\Eclipse Adoptium\jdk-17.0.18.8-hotspot\bin\java.exe'
is specified by the OIE_JAVA_PATH environment variable, which is not a valid
Java executable of at least version 17. Exiting.

The executable exists and successfully reports:

openjdk version "17.0.18"

Screenshots

Not applicable. The complete error is available in the PowerShell output.

Environment

  • OS: Windows 10
  • Shell: Windows PowerShell
  • Java Distribution/Version: Eclipse Temurin OpenJDK 17.0.18
  • Connect Version: Open Integration Engine 4.6.0
  • Launcher: oieserver.ps1

Workaround(s)

Run the server through Gradle instead:

cd %location_of_engine%\engine
.\gradlew.bat :server:devRun --no-daemon

Activity

  1. added
    bug
    on Jul 29, 2026
  2. kryskool commented on Aug 24, 2026

    @kryskool
    Contributor

    Hi @eddcomeau

    After you declare your environment variable can you try to launch this command

    & $env:OIE_JAVA_PATH -version

    Regards,

  3. discofris commented on Aug 26, 2026

    @discofris

    I came to the conclusion that it's a PowerShell version issue:
    "PowerShell 7 doesn't turn native stderr into a terminating error the same way, so the version parse runs and sees your 25.0.4. This script is clearly written for PowerShell 7 anyway — it uses $env:HOME, tilde expansion, and [System.IO.Path] constructs aimed at cross-platform pwsh — so 5.1 was never really the intended host. When you launch .\oieserver.ps1 from a normal Windows console it defaults to 5.1, which is how you ended up here."

    My 2022 box has default PS 5.1. How I fixed it (line 145)

    try {
            $ErrorActionPreference = 'Continue'   # <-- add this line (PS 5.1 stderr fix)
            $versionOutput = & $JavaCmd -version 2>&1
        }
    

    Another fix would be to install PowerShell 7.

    So oieserver.ps1 works now, but oieserver.exe does not.

  4. jonbartels commented on Aug 26, 2026

    @jonbartels
    Contributor

    #419 @eddcomeau @kryskool and @discofris

    Can you try this PR and see if it solves the issue? You can leave a PR review with your feedback

  5. added this to the Next Release milestone on Sep 24, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    bug

    Type

    No type

    Projects

    No projects

      Milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions