Solution 1 :
You can set up JDK for your project in File|Project Structure|SDK Location|JDK Location
.
Problem :
Everyone in this thread suggest to set the Gradle JVM to version 1.8, but I just cannot find that version in Intellij.
File -> Settings -> Build, Execution, Deployment -> Build Tools -> Gradle leads me to:
Project structure doesn’t help either:
There is no place in Intellij where I can set the Gradle JVM version.
Gradle:
compileOptions {
sourceCompatibility JavaVersion.VERSION_11
targetCompatibility JavaVersion.VERSION_11
}
I know AS requires JDK 8, but I saw some people pull off using 11 in the compileOptions by setting Gradle JVM to 8, but I can’t do that on my Intellij for some reason.