Increase timeout for gradle to get a maven dependency

前端 未结 1 1135
故里飘歌
故里飘歌 2021-02-04 02:54

I am tring to get a jar dependency from Maven via the grails 3.1.5 gradle dependency Resolution . How do I increase timeout that gradle takes to ge

1条回答
  •  梦如初夏
    2021-02-04 03:25

    The feature was added in Gradle here: https://github.com/gradle/gradle/pull/3041

    You can increase the timeout with 2 properties:

    ./gradlew build -Dhttp.socketTimeout=60000 -Dhttp.connectionTimeout=60000
    

    As commented by Sue C, If you are using gradle 4.10.2 or later version use following properties:

    ./gradlew build -Dorg.gradle.internal.http.socketTimeout=60000 -Dorg.gradle.internal.http.connectionTimeout=60000

    0 讨论(0)
提交回复
热议问题