Logstash Keystore No java.exe executable found on PATH

Hello,
I am trying to use the keystore, that the passwords in the pipeline are not in plain text. I did not download any JDK. I used the bundled jdk which is included in the logstash download. I am getting these message:

C:\path to logstash\logstash-8.0.1>bin\logstash-keystore.bat create
"Using bundled JDK: ."
No `java.exe' executable found on PATH.

My logstash-keystore.bat looks like that. From previous problems I know I somehow need to change the path there. My problem is where in this code and what exactly?

@echo off
setlocal enabledelayedexpansion

call "%~dp0setup.bat" || exit /b 1
if errorlevel 1 (
	if not defined nopauseonerror (
		pause
	)
	exit /B %ERRORLEVEL%
)

%JRUBY_BIN% "%LS_HOME%\lib\secretstore\cli.rb" %*
if errorlevel 1 (
  exit /B 1
)

endlocal

Hello !

The error speaks for itselfs, your system is not able to call the java executable from your PATH variable.

You need to make sure your system is aware of your java installation by setting system variable JAVA_HOME or edit your PATH system variable to append the JAVA executable directory.

This might help IBM Docs !