title: How do I upgrade java from 1.8 to 11
body: <p>I have an android app I am building using Android Studio.  All of a sudden I received a build.gradle warning: Android Gradle plugin requires Java 11 to run.  You are currently using Java 1.8.</p>
  <p>the problem I see refers to the second line in this code;</p>
  <pre><code>plugins {
  id 'com.android.application'
  id 'kotlin-android'
  }
  </code></pre>
  <p>I am running Android Studio on a MacBook pro.
  I have tried various fixes but most are for PC and since I am using a Mac they don't seem to help.</p>
  <p>Does anyone have a solution.</p>