It seems like you’re having the JAVA_HOME set in your mvn.bat. It could be pointing to the older version of Java (i.e., 8 in your case).
set JAVA_HOME=C:\path\to\jdk11. Try using it on the first line, before calling Maven.
It seems like you’re having the JAVA_HOME set in your mvn.bat. It could be pointing to the older version of Java (i.e., 8 in your case).
set JAVA_HOME=C:\path\to\jdk11. Try using it on the first line, before calling Maven.