Gradle Build failing with Java 11

Getting an Exception like this while compiling with Gradle

./gradlew :distribution:archives:windows-zip:assemble

**Execution failed for task ':x-pack:plugin:moni**
**> java.lang.AssertionError: isSubtype UNKNOWN**

OS : windows 7
Java : 11
Gradle : 6.6.1

Please share the full build output, including a full exception. Also please share some information what branch you are trying to build.

That said, you should get a detailed error message regarding the java version, as building Elasticsearch (compared to runnig) usually requires one of the latest java versions.