0
votes

I have done two hybris project setups as (Hybris v5.6 - Java 1.8) and (Hybris v20.005 - Java 11). I switch the Java-11 to Java-1.8 (jdk,jre bin path settings) at system env variables, to make the (Hybris v5.6) running.

Even though the system env variables are set up with Java-1.8 but the ant build at the (Hybris v5.6) gives the error message as below and says current Java version is :11 (see the below message clearly). I have cross-verified java version on command prompt using the command (java -version) and it says as (openjdk version "1.8.0_242")

**** WRONG JAVA VERSION **** Environment check failed: You are using a not supported version of Java. Please make sure you are using Java version 1.7 or later.  Your current Java version is: 11

Please give me a clue from where it could override the java version or any other solutions?

Thanks Kishore

1
Did you check JAVA_HOME environment variable? - Johannes Nolte
Please also check build.target property from hybris\bin\platform\resources\advanced.properties. Its value should be 1.8 - dj_frunza
we already updated the JAVA_HOME to jdk1.8 and the advanced.properties build.target is set with 1.8. - user3691164

1 Answers

0
votes

We found something to make the build successful, by running the commands below to set JAVA_HOME and PATH, before doing the ant build (ant all or ant clean all) at the command prompt.

SET JAVA_HOME='C:\Program Files\Java\jdk1.8'
set PATH=C:\Program Files\Java\jdk1.8\bin;%PATH%

Thanks Kishore.