Gradle plugins not able to resolve plugins dependencies

I am encountering an issue with Gradle when attempting to run a task on a Linux server. Despite having the correct Java and Gradle versions configured, I am getting SSL misconfiguration errors when Gradle tries to resolve plugins. Here’s a detailed breakdown of my setup and the error:


Gradle version: 8.8
Java version: openjdk version “1.8.0_412”
Java home: Set in /etc/profile as

export JAVA_HOME=/usr/lib/jvm/jre-1.8.0-openjdk-
export PATH=$JAVA_HOME/bin:$PATH


buildscript {
    repositories {
        flatDir {
            dirs 'lib'

plugins {
    id 'com.github.node-gradle.node' version '2.2.0'
    id '' version '4.8.0'

repositories {
    maven {
        url ''

configurations {

dependencies {
    mlcp 'com.marklogic:mlcp:'
    mlcp files('lib')

node {
    version = '10.5.0'
    npmVersion = '6.1.0'
    download = true

Error when running following command

**./gradlew taskname -PmlHost=“localhost” on the linux server, getting following error : **

2024-06-07T18:10:27.221+0000 [DEBUG] [org.apache.http.impl.execchain.MainClientExec] Opening connection {s}->
2024-06-07T18:10:27.224+0000 [DEBUG] [org.apache.http.impl.conn.DefaultHttpClientConnectionOperator] Connecting to
2024-06-07T18:10:27.224+0000 [DEBUG] [org.apache.http.conn.ssl.SSLConnectionSocketFactory] Connecting socket to with timeout 30000
> Could not resolve com.github.node-gradle:gradle-node-plugin:2.2.0.
   > Could not get resource ''.
      > Could not GET ''.
         > Got socket exception during request. It might be caused by SSL misconfiguration
            > Connect to [,,,] failed: Network is unreachable (connect failed)

However, when I use curl to check the connection, I get a 200 OK response:

curl -I ""

and same code when I am running on my local system it is work fine
There I am using java version “1.8.0_202”

Why does Gradle fail to resolve the plugin due to an SSL misconfiguration even though curl works fine? How can I resolve this SSL misconfiguration to allow Gradle to successfully connect to the plugin repository?

Any help or insights into this issue would be greatly appreciated!

Why does Gradle fail to resolve the plugin due to an SSL misconfiguration even though curl works fine?

I don’t think it is an SSL misconfiguration.
It says “might be caused by” since 8.3.0, probably because that is a typical cause for that error.
But if you look at the actual error one line below, it says

Network is unreachable (connect failed)

That curl works is just an indication, but not a proof.

I’d guess that you need to use some proxy to access the internet, which is configured for curl, but not for Gradle. See Networking with Gradle for more info on that.

Hi @Vampire , thank you for suggestion

But after using proxy also in

getting this error

> Could not resolve com.github.node-gradle:gradle-node-plugin:2.2.0.
     Required by:
         project : > com.github.node-gradle.node:com.github.node-gradle.node.gradle.plugin:2.2.0
      > Could not resolve com.github.node-gradle:gradle-node-plugin:2.2.0.
         > Could not get resource ''.
            > Could not GET ''.

and in debug mode it showing like this

2024-06-10T13:31:36.827+0000 [DEBUG] [org.apache.http.impl.conn.PoolingHttpClientConnectionManager] Connection [id: 17][route: {tls}->http://proxy:port->] can be kept alive indefinitely
2024-06-10T13:31:36.827+0000 [DEBUG] [org.apache.http.impl.conn.DefaultManagedHttpClientConnection] http-outgoing-17: set socket timeout to 0
2024-06-10T13:31:36.828+0000 [DEBUG] [org.apache.http.impl.conn.PoolingHttpClientConnectionManager] Connection released: [id: 17][route: {tls}->http://proxy:port->][total available: 1; route allocated: 1 of 20; total allocated: 1 of 20]
2024-06-10T13:31:36.828+0000 [DEBUG] [org.gradle.internal.resource.transport.http.AlwaysFollowAndPreserveMethodRedirectStrategy] Redirect requested to location ''
2024-06-10T13:31:36.828+0000 [DEBUG] [org.apache.http.impl.execchain.RedirectExec] Resetting target auth state
2024-06-10T13:31:36.828+0000 [DEBUG] [org.apache.http.impl.execchain.RedirectExec] Redirecting to '' via {tls}->http://proxy:port->
2024-06-10T13:31:36.828+0000 [DEBUG] [org.apache.http.client.protocol.RequestAddCookies] CookieSpec selected: default
2024-06-10T13:31:36.828+0000 [DEBUG] [org.apache.http.client.protocol.RequestAuthCache] Auth cache not set in the context
2024-06-10T13:31:36.828+0000 [DEBUG] [org.apache.http.impl.conn.PoolingHttpClientConnectionManager] Connection request: [route: {tls}->http://proxy:port->][total available: 1; route allocated: 0 of 20; total allocated: 1 of 20]
2024-06-10T13:31:36.829+0000 [DEBUG] [org.apache.http.impl.conn.PoolingHttpClientConnectionManager] Connection leased: [id: 18][route: {tls}->http://proxy:port->][total available: 1; route allocated: 1 of 20; total allocated: 2 of 20]
2024-06-10T13:31:36.829+0000 [DEBUG] [org.apache.http.impl.execchain.MainClientExec] Opening connection {tls}->http://proxy:port->
2024-06-10T13:31:36.829+0000 [DEBUG] [org.apache.http.impl.conn.DefaultHttpClientConnectionOperator] Connecting to proxy/ip:port
2024-06-10T13:31:36.842+0000 [DEBUG] [org.apache.http.impl.conn.DefaultHttpClientConnectionOperator] Connection established ip1:port1<->ip:port
2024-06-10T13:31:36.886+0000 [DEBUG] [org.apache.http.impl.execchain.MainClientExec] Tunnel to target created.
2024-06-10T13:31:36.886+0000 [DEBUG] [org.apache.http.conn.ssl.SSLConnectionSocketFactory] Enabled protocols: [TLSversion, TLSversion]
2024-06-10T13:31:36.886+0000 [DEBUG] [org.apache.http.conn.ssl.SSLConnectionSocketFactory] Enabled cipher suites:[]
2024-06-10T13:31:36.886+0000 [DEBUG] [org.apache.http.conn.ssl.SSLConnectionSocketFactory] Starting handshake
2024-06-10T13:31:36.922+0000 [DEBUG] [org.apache.http.conn.ssl.SSLConnectionSocketFactory] Secure session established
2024-06-10T13:31:36.922+0000 [DEBUG] [org.apache.http.conn.ssl.SSLConnectionSocketFactory]  negotiated protocol: TLSvversion
2024-06-10T13:31:36.922+0000 [DEBUG] [org.apache.http.conn.ssl.SSLConnectionSocketFactory]  negotiated cipher suite: TLS
2024-06-10T13:31:36.923+0000 [DEBUG] [org.apache.http.conn.ssl.SSLConnectionSocketFactory]  peer principal:, O="Cisco Systems, Inc."
2024-06-10T13:31:36.923+0000 [DEBUG] [org.apache.http.conn.ssl.SSLConnectionSocketFactory]  peer alternative names: []
2024-06-10T13:31:36.923+0000 [DEBUG] [org.apache.http.conn.ssl.SSLConnectionSocketFactory]  issuer principal: CN=Cisco Umbrella
2024-06-10T13:31:36.923+0000 [DEBUG] [org.apache.http.impl.conn.DefaultManagedHttpClientConnection] http-outgoing-18: set socket timeout to 30000
2024-06-10T13:31:36.923+0000 [DEBUG] [org.apache.http.impl.execchain.MainClientExec] Executing request GET /com.github.node-gradle/gradle-node-plugin/2.2.0/8a8d8d9c9a05f28650dda340493dc23a9099e049a49ca39b15799b890ccc8f4c/gradle-node-plugin-2.2.0.pom HTTP/1.1
2024-06-10T13:31:36.923+0000 [DEBUG] [org.apache.http.impl.execchain.MainClientExec] Target auth state: UNCHALLENGED
2024-06-10T13:31:36.946+0000 [DEBUG] [org.apache.http.impl.execchain.MainClientExec] Connection can be kept alive indefinitely
2024-06-10T13:31:36.947+0000 [DEBUG] [org.apache.http.client.protocol.ResponseProcessCookies] Cookie accepted [X-OpenDNS-Session="830f90b506290040c7098eb0eb590c4f5a4f9270fc53_BZAQUSAB", version:0,, path:/, expiry:Mon Jun 10 13:36:36 UTC 2024]
2024-06-10T13:31:36.947+0000 [DEBUG] [org.gradle.internal.resource.transport.http.AlwaysFollowAndPreserveMethodRedirectStrategy] Redirect requested to location ''
2024-06-10T13:31:36.947+0000 [DEBUG] [org.apache.http.impl.execchain.RedirectExec] Resetting target auth state
2024-06-10T13:31:36.947+0000 [DEBUG] [org.apache.http.impl.execchain.RedirectExec] Redirecting to '' via {tls}->http://proxy:port->
2024-06-10T13:31:36.947+0000 [DEBUG] [org.apache.http.impl.conn.PoolingHttpClientConnectionManager] Connection [id: 18][route: {tls}->http://proxy:port->] can be kept alive indefinitely
2024-06-10T13:31:36.947+0000 [DEBUG] [org.apache.http.impl.conn.DefaultManagedHttpClientConnection] http-outgoing-18: set socket timeout to 0
2024-06-10T13:31:36.947+0000 [DEBUG] [org.apache.http.impl.conn.PoolingHttpClientConnectionManager] Connection released: [id: 18][route: {tls}->http://proxy:port->][total available: 2; route allocated: 1 of 20; total allocated: 2 of 20]
2024-06-10T13:31:36.947+0000 [DEBUG] [org.apache.http.client.protocol.RequestAddCookies] CookieSpec selected: default
2024-06-10T13:31:36.947+0000 [DEBUG] [org.apache.http.client.protocol.RequestAuthCache] Auth cache not set in the context

with curl
curl -I ‘
getting this
HTTP/1.1 200 Connection established

HTTP/1.1 303 See Other
Date: Mon, 10 Jun 2024 14:31:00 GMT
Content-Length: 0
Connection: keep-alive

Could you please suggest how will I fix this ?

I have no idea how your proxy needs to be configured, sorry.
Maybe you should seek help from your network administrator.

I have checked with network team as per them proxy is properly configured. we tried to clean .gradle file then ran gradle command to install gradle wrapper, it is installing that correctly, which we do not work without proxy and also there is nothing in debug that shows connection not successful, we have gone through it and found nothing like that but in end it throwing that exception and when using wget to same url, the pom and jre file are downloaded successfully.
In our company we are using cisco umbrella, is it be the one behind it as I gone through one of discussion page on which Download Wrapper fails with SSLHandshakeException stacktrace - #5 by DJViking.

Any insights or suggestions would be greatly appreciated.

I’m sorry, but from remote I have no idea. If you think the proxy is configured properly but it does not work, maybe it is some uncommon proxy setup that is not supported or buggy. In that case it might make sense to open an issue ticket on GitHub.