Skip to content

Fix SSH agents hanging on Java 17 (#32) - #33

Merged
shenxianpeng merged 1 commit into
mainfrom
fix-ssh-stdout-32
Nov 2, 2026
Merged

shenxianpeng merged 1 commit into
mainfrom
fix-ssh-stdout-32

Conversation

@shenxianpeng

@shenxianpeng shenxianpeng commented Nov 2, 2026 •

Copy link
Copy Markdown
Collaborator

Before: with the SSH Build Agents launcher, an agent on Java 17 hangs after channel started and never comes online (#32). Java 8 agents and inbound agents are not affected.

After: the agent comes online and runs builds on Java 17 over SSH.

With the SSH launcher, the agent's standard output is the remoting channel. JvmDowngrader's loggers write to the System.out they see when its Java agent starts, so a log line from them went into the channel and the controller's reader waited mid-chunk for data that never came.

How: agent8's Java agent, which starts before JvmDowngrader's, points System.out at standard error; Main puts the real standard output back before remoting starts. CI: the SSH launcher job also runs on Java 17 (test/ssh.sh skips the signed provider checks there, since they use the Java 8 extension directory). Reproduced and verified on a temporary branch against Jenkins 2.580.1: hang before, agent online and freestyle build passing after.

Refs #32 (left open until the reporter confirms on Solaris)

…#32)

With the SSH Build Agents launcher, the agent's standard output is the
remoting channel. JvmDowngrader's loggers write to the System.out they
see when its Java agent starts, so a log line from them went into the
channel and the agent hung after 'channel started'. agent8's Java agent
now points System.out at standard error while JvmDowngrader starts, and
Main puts it back before remoting starts.

CI: the SSH launcher job also runs on Java 17.
@shenxianpeng shenxianpeng added the bug Something isn't working label Nov 2, 2026
@shenxianpeng
shenxianpeng merged commit cdad04b into main Nov 2, 2026
18 checks passed
@shenxianpeng
shenxianpeng deleted the fix-ssh-stdout-32 branch November 2, 2026 13:56
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

bug Something isn't working

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant