Skip to content

Issue with Java 25 with jdk.net.Sockets #119

@jonesbusy

Description

@jonesbusy

Jenkins and plugins versions report

Environment
Jenkins: 2.547
OS: Linux - 6.6.87.2-microsoft-standard-WSL2
Java: 25.0.1 - Eclipse Adoptium (OpenJDK 64-Bit Server VM)
---
antisamy-markup-formatter:173.v680e3a_b_69ff3
apache-httpcomponents-client-4-api:4.5.14-269.vfa_2321039a_83
apache-httpcomponents-client-5-api:5.6-183.ve5a_8a_b_e71e59
asm-api:9.9.1-189.vb_5ef2964da_91
bootstrap5-api:5.3.8-895.v4d0d8e47fea_d
bouncycastle-api:2.30.1.82-277.v70ca_0b_877184
branch-api:2.1268.v044a_87612da_8
caffeine-api:3.2.3-194.v31a_b_f7a_b_5a_81
cloudbees-folder:6.1073.va_7888eb_dd514
commons-lang3-api:3.20.0-109.ve43756e2d2b_4
commons-text-api:1.15.0-210.v7480a_da_70b_9e
configuration-as-code:2006.v001a_2ca_6b_574
credentials:1480.v2246fd131e83
credentials-binding:702.vfe613e537e88
display-url-api:2.217.va_6b_de84cc74b_
durable-task:651.v1f5e074fc83f
font-awesome-api:7.1.0-882.v1dfb_771e3278
git:5.8.1
git-client:6.5.0
gson-api:2.13.2-173.va_a_092315913c
http_request:1.24
instance-identity:203.v15e81a_1b_7a_38
ionicons-api:94.vcc3065403257
jackson2-api:2.20.1-423.v13951f6b_6532
jakarta-activation-api:2.1.4-1
jakarta-mail-api:2.1.5-1
jakarta-xml-bind-api:4.0.6-12.vb_1833c1231d3
javax-activation-api:1.2.0-8
jaxb:2.3.9-143.v5979df3304e6
job-dsl:1.93
joda-time-api:2.14.0-177.vd7e9347b_e7d5
json-api:20251224-185.v0cc18490c62c
mailer:525.v2458b_d8a_1a_71
mina-sshd-api-common:2.16.0-167.va_269f38cc024
mina-sshd-api-core:2.16.0-167.va_269f38cc024
pipeline-groovy-lib:787.ve2fef0efdca_6
pipeline-input-step:540.v14b_100d754dd
pipeline-model-api:2.2277.v00573e73ddf1
pipeline-model-definition:2.2277.v00573e73ddf1
pipeline-model-extensions:2.2277.v00573e73ddf1
pipeline-stage-step:322.vecffa_99f371c
pipeline-stage-tags-metadata:2.2277.v00573e73ddf1
plain-credentials:199.v9f8e1f741799
plugin-util-api:6.1192.v30fe6e2837ff
prism-api:1.30.0-630.va_e19d17f83b_0
scm-api:724.v7d839074eb_5c
script-security:1385.v7d2d9ec4d909
snakeyaml-api:2.5-143.v93b_c004f89de
ssh-credentials:361.vb_f6760818e8c
strict-crumb-issuer:2.1.1
structs:362.va_b_695ef4fdf9
variant:70.va_d9f17f859e0
workflow-api:1398.v67030756d3fb_
workflow-basic-steps:1098.v808b_fd7f8cf4
workflow-cps:4252.v465f588eb_52f
workflow-durable-task-step:1464.v2d3f5c68f84c
workflow-job:1559.va_a_533730b_ea_d
workflow-multibranch:821.vc3b_4ea_780798
workflow-scm-step:466.va_d69e602552b_
workflow-step-api:710.v3e456cc85233
workflow-support:1010.vb_b_39488a_9841

What Operating System are you using (both controller, and any agents involved in the problem)?

See https://github.com/jonesbusy/jenkins-reproduce/tree/main/http-socket-java-25

Reproduction steps

There is reproducer here See https://github.com/jonesbusy/jenkins-reproduce/tree/main/http-socket-java-25

But basically

Controller: jenkins/jenkins:2.547-jdk25
Inbound agent: jenkins/inbound-agent:3355.v388858a_47b_33-5-jdk25

Pipeline

stage('Controller') {
    httpRequest responseHandle: 'NONE', url: 'https://www.google.com', wrapAsMultipart: false
}
stage('Agent') {
    node('agent') {
        httpRequest responseHandle: 'NONE', url: 'https://www.google.com', wrapAsMultipart: false
    }
}

Expected Results

It works

Actual Results

Also:   hudson.remoting.Channel$CallSiteStackTrace: Remote call to JNLP4-connect connection to jenkins/10.89.1.9:50000
		at hudson.remoting.Channel.attachCallSiteStackTrace(Channel.java:1916)
		at hudson.remoting.Request.call(Request.java:204)
		at hudson.remoting.RemoteInvocationHandler.invoke(RemoteInvocationHandler.java:312)
		at jdk.proxy2/jdk.proxy2.$Proxy7.fetch3(Unknown Source)
		at hudson.remoting.RemoteClassLoader.prefetchClassReference(RemoteClassLoader.java:363)
		at hudson.remoting.RemoteClassLoader.loadWithMultiClassLoader(RemoteClassLoader.java:266)
		at hudson.remoting.RemoteClassLoader.findClass(RemoteClassLoader.java:236)
		at java.base/java.lang.ClassLoader.loadClass(Unknown Source)
		at java.base/java.lang.ClassLoader.loadClass(Unknown Source)
		at PluginClassLoader for apache-httpcomponents-client-5-api//org.apache.hc.client5.http.impl.io.DefaultHttpClientConnectionOperator.<clinit>(DefaultHttpClientConnectionOperator.java:87)
		at PluginClassLoader for apache-httpcomponents-client-5-api//org.apache.hc.client5.http.impl.io.PoolingHttpClientConnectionManager.<init>(PoolingHttpClientConnectionManager.java:132)
		at PluginClassLoader for http_request//jenkins.plugins.http_request.HttpRequestExecution.configureTimeoutAndSsl(HttpRequestExecution.java:403)
		at PluginClassLoader for http_request//jenkins.plugins.http_request.HttpRequestExecution.authAndRequest(HttpRequestExecution.java:320)
		at PluginClassLoader for http_request//jenkins.plugins.http_request.HttpRequestExecution.call(HttpRequestExecution.java:293)
		at PluginClassLoader for http_request//jenkins.plugins.http_request.HttpRequestExecution.call(HttpRequestExecution.java:88)
		at hudson.remoting.UserRequest.perform(UserRequest.java:225)
		at hudson.remoting.UserRequest.perform(UserRequest.java:50)
		at hudson.remoting.Request$2.run(Request.java:391)
		at hudson.remoting.InterceptingExecutorService.lambda$wrap$0(InterceptingExecutorService.java:81)
		at java.base/java.util.concurrent.FutureTask.run(Unknown Source)
		at java.base/java.util.concurrent.ThreadPoolExecutor.runWorker(Unknown Source)
		at java.base/java.util.concurrent.ThreadPoolExecutor$Worker.run(Unknown Source)
		at hudson.remoting.Engine$1.lambda$newThread$0(Engine.java:312)
		at java.base/java.lang.Thread.run(Unknown Source)
java.lang.ClassNotFoundException: Bootstrap pseudo-classloader disabled: jdk.net.Sockets via null
	at hudson.remoting.RemoteClassLoader$ClassLoaderProxy.fetch4(RemoteClassLoader.java:1082)
	at hudson.remoting.RemoteClassLoader$ClassLoaderProxy.fetch3(RemoteClassLoader.java:1123)
	at java.base/jdk.internal.reflect.DirectMethodHandleAccessor.invoke(DirectMethodHandleAccessor.java:104)
	at java.base/java.lang.reflect.Method.invoke(Method.java:565)
	at hudson.remoting.RemoteInvocationHandler$RPCRequest.perform(RemoteInvocationHandler.java:986)
	at hudson.remoting.Request$2.run(Request.java:391)
	at hudson.remoting.InterceptingExecutorService.lambda$wrap$0(InterceptingExecutorService.java:81)
	at org.jenkinsci.remoting.CallableDecorator.call(CallableDecorator.java:18)
	at hudson.remoting.CallableDecoratorList.lambda$applyDecorator$0(CallableDecoratorList.java:21)
	at jenkins.util.ContextResettingExecutorService$2.call(ContextResettingExecutorService.java:46)
	at jenkins.security.ImpersonatingExecutorService$2.call(ImpersonatingExecutorService.java:80)
	at java.base/java.util.concurrent.FutureTask.run(FutureTask.java:328)
	at java.base/java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1090)
	at java.base/java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:614)
	at java.base/java.lang.Thread.run(Thread.java:1474)
Also:   hudson.remoting.Channel$CallSiteStackTrace: Remote call to JNLP4-connect connection from 10.89.1.11/10.89.1.11:39066
		at hudson.remoting.Channel.attachCallSiteStackTrace(Channel.java:1916)
		at hudson.remoting.UserRequest$ExceptionResponse.retrieve(UserRequest.java:384)
		at hudson.remoting.Channel.call(Channel.java:1108)
		at PluginClassLoader for http_request//jenkins.plugins.http_request.HttpRequestStep$Execution.run(HttpRequestStep.java:405)
		at PluginClassLoader for http_request//jenkins.plugins.http_request.HttpRequestStep$Execution.run(HttpRequestStep.java:384)
		at PluginClassLoader for workflow-step-api//org.jenkinsci.plugins.workflow.steps.SynchronousNonBlockingStepExecution.lambda$start$0(SynchronousNonBlockingStepExecution.java:49)
		at java.base/java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:545)
		at java.base/java.util.concurrent.FutureTask.run(FutureTask.java:328)
		at java.base/java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1090)
		at java.base/java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:614)
		at java.base/java.lang.Thread.run(Thread.java:1474)
Caused: java.lang.NoClassDefFoundError: jdk/net/Sockets
	at PluginClassLoader for apache-httpcomponents-client-5-api//org.apache.hc.client5.http.impl.io.DefaultHttpClientConnectionOperator.<clinit>(DefaultHttpClientConnectionOperator.java:87)
	at PluginClassLoader for apache-httpcomponents-client-5-api//org.apache.hc.client5.http.impl.io.PoolingHttpClientConnectionManager.<init>(PoolingHttpClientConnectionManager.java:132)
	at PluginClassLoader for http_request//jenkins.plugins.http_request.HttpRequestExecution.configureTimeoutAndSsl(HttpRequestExecution.java:403)
	at PluginClassLoader for http_request//jenkins.plugins.http_request.HttpRequestExecution.authAndRequest(HttpRequestExecution.java:320)
	at PluginClassLoader for http_request//jenkins.plugins.http_request.HttpRequestExecution.call(HttpRequestExecution.java:293)
	at PluginClassLoader for http_request//jenkins.plugins.http_request.HttpRequestExecution.call(HttpRequestExecution.java:88)
	at hudson.remoting.UserRequest.perform(UserRequest.java:225)
	at hudson.remoting.UserRequest.perform(UserRequest.java:50)
	at hudson.remoting.Request$2.run(Request.java:391)
	at hudson.remoting.InterceptingExecutorService.lambda$wrap$0(InterceptingExecutorService.java:81)
	at java.base/java.util.concurrent.FutureTask.run(Unknown Source)
	at java.base/java.util.concurrent.ThreadPoolExecutor.runWorker(Unknown Source)
	at java.base/java.util.concurrent.ThreadPoolExecutor$Worker.run(Unknown Source)
	at hudson.remoting.Engine$1.lambda$newThread$0(Engine.java:312)
	at java.base/java.lang.Thread.run(Unknown Source)
Also:   org.jenkinsci.plugins.workflow.actions.ErrorAction$ErrorId: 9a628d46-9470-45be-998e-2eedb601cbe6
Caused: java.io.IOException: Remote call on JNLP4-connect connection from 10.89.1.11/10.89.1.11:39066 failed
	at hudson.remoting.Channel.call(Channel.java:1112)
	at PluginClassLoader for http_request//jenkins.plugins.http_request.HttpRequestStep$Execution.run(HttpRequestStep.java:405)
	at PluginClassLoader for http_request//jenkins.plugins.http_request.HttpRequestStep$Execution.run(HttpRequestStep.java:384)
	at PluginClassLoader for workflow-step-api//org.jenkinsci.plugins.workflow.steps.SynchronousNonBlockingStepExecution.lambda$start$0(SynchronousNonBlockingStepExecution.java:49)
	at java.base/java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:545)
	at java.base/java.util.concurrent.FutureTask.run(FutureTask.java:328)
	at java.base/java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1090)
	at java.base/java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:614)
	at java.base/java.lang.Thread.run(Thread.java:1474)

To be honnest I open this issue there, but I do not have any idea which is the root cause

  • Underlying apache client 5?
  • Jenkins remoting (since it's working on the controller?
  • Packaging of Jenkins container image?

Anything else?

No response

Are you interested in contributing a fix?

Nope, but I can help with debug and tesing some PR / container image

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions