I\'m trying to build Java 8 project with Gradle 1.6, but I\'m stuck on this error:
Execution failed for task \':ejb:compileJava\' invalid target release: 1.8
I found picking wrong JAVA_HOME path value. After updating correct path, it's working for me. No need to do any change.
Found the answer. I replaced JAVA_HOME
D:\Program Files\Java\jdk1.8.0
with
D:\Progra~2\Java\jdk1.8.0
and build succeeded.