max max - 1 month ago 21
Android Question

android studio error Error:Connection timed out

I just create a new Project in the android studio and add gcm module to it.

and I keep giving this error message

Error:Connection timed out: connect. If you are behind an HTTP proxy, please configure the proxy settings either in IDE or Gradle.


and I do not use any proxy.

can anyone help me about this?

Update

now after rebuild my project i give this error

Error:A problem occurred configuring project ':app'.
A problem occurred configuring project ':backend'.
Could not resolve all dependencies for configuration ':backend:classpath'.
Could not resolve com.google.appengine:gradle-appengine-plugin:1.9.18.
Required by:
PushStart:backend:unspecified
Could not resolve com.google.appengine:gradle-appengine-plugin:1.9.18.
Could not get resource 'https://jcenter.bintray.com/com/google/appengine/gradle-appengine-plugin/1.9.18/gradle-appengine-plugin-1.9.18.pom'.
Could not GET 'https://jcenter.bintray.com/com/google/appengine/gradle-appengine-plugin/1.9.18/gradle-appengine-plugin-1.9.18.pom'.
Connection to https://jcenter.bintray.com refused

Answer

The answer from this SO post might help you.

You should add the below lines in the gradle.properties file for the https setings configuration

    systemProp.https.proxyHost=www.somehost.org
    systemProp.https.proxyPort=8080
    systemProp.https.proxyUser=userid
    systemProp.https.proxyPassword=password
    systemProp.https.nonProxyHosts=*.nonproxyrepos.com|localhost
Comments