title: Could Not build Flutter Android Build : Received status code 502 from bintray
body: <p>Hi I am trying to run my flutter app debug. I last opened this app on November 3rd week but Today when I build the app debug I am facing below exception. I've been told that bintray has been sunset, but confused as how to replace/update my gradle.</p>
  <pre><code>FAILURE: Build failed with an exception.
  
  * What went wrong:
  Could not determine the dependencies of task ':app:preDebugBuild'.
  &gt; Could not resolve all task dependencies for configuration ':app:debugRuntimeClasspath'.
     &gt; Could not resolve com.onesignal:OneSignal:[3.11.2,3.99.99].
       Required by:
           project :app
        &gt; Failed to list versions for com.onesignal:OneSignal.
           &gt; Unable to load Maven meta-data from https://google.bintray.com/exoplayer/com/onesignal/OneSignal/maven-metadata.xml.
              &gt; Could not get resource 'https://google.bintray.com/exoplayer/com/onesignal/OneSignal/maven-metadata.xml'.
                 &gt; Could not GET 'https://google.bintray.com/exoplayer/com/onesignal/OneSignal/maven-metadata.xml'. Received status code 502 from server: Bad Gateway
  
  * Try:
  Run with --stacktrace option to get the stack trace. Run with --info or --debug option to get more log output. Run with --scan to get full insights.
  
  * Get more help at https://help.gradle.org
  
  BUILD FAILED in 18s
  Exception: Gradle task assembleDebug failed with exit code 1
  </code></pre>
  <p>These are my Flutter and Dart Versions:</p>
  <ul>
  <li>Flutter 1.17.5</li>
  <li>Dart Dart 2.8.4</li>
  </ul>
  <p>OneSignal Plugin</p>
  <pre><code>onesignal_flutter: ^2.6.4
  </code></pre>
  <p>Distribution URL in gradle.properties:</p>
  <pre><code>distributionUrl=https\://services.gradle.org/distributions/gradle-6.7-all.zip
  </code></pre>
  <p>Project Level Gradle:</p>
  <pre><code>buildscript {
      repositories {
          google()
          mavenCentral()
  //        jcenter()
          maven {
             url 'https://maven.fabric.io/public'
          }
      }
  
      dependencies {
          classpath 'com.android.tools.build:gradle:4.0.1'
          classpath 'com.google.gms:google-services:3.2.1'   // new
          classpath 'io.fabric.tools:gradle:1.+'
      }
  
      // #jf1dt support multidex + androidX
      subprojects {
          project.configurations.all {
              resolutionStrategy.eachDependency { details -&gt;
                  if (details.requested.group == 'com.android.support'
                          &amp;&amp; !details.requested.name.contains('multidex') ) {
                      details.useVersion &quot;27.1.1&quot;
                  }
  
                  if (details.requested.group == 'androidx.core'
                          &amp;&amp; !details.requested.name.contains('androidx') ) {
                      details.useVersion &quot;1.0.1&quot;
                  }
              }
          }
      }
  }
  
  allprojects {
      repositories {
          mavenCentral()
          google()
  //        jcenter()
      }
  }
  
  rootProject.buildDir = '../build'
  subprojects {
      project.buildDir = &quot;${rootProject.buildDir}/${project.name}&quot;
  }
  subprojects {
      project.evaluationDependsOn(':app')
  }
  
  task clean(type: Delete) {
      delete rootProject.buildDir
  }
  </code></pre>