-
Bug
-
Resolution: Unresolved
-
Major
-
None
There's a report from users that indicates a CLI client can hang at the following spot:
java.lang.Thread.State: RUNNABLE at java.net.SocketInputStream.socketRead0(Native Method) at java.net.SocketInputStream.read(Unknown Source) at java.io.FilterInputStream.read(Unknown Source) at java.io.FilterInputStream.read(Unknown Source) at javax.crypto.CipherInputStream.a(DashoA13*..) at javax.crypto.CipherInputStream.read(DashoA13*..) at java.io.DataInputStream.readFully(Unknown Source) at java.io.DataInputStream.readFully(Unknown Source) at hudson.cli.Connection.readByteArray(Connection.java:132) at hudson.cli.CLI.connectViaCliPort(CLI.java:243) at hudson.cli.CLI.<init>(CLI.java:134) at hudson.cli.CLIConnectionFactory.connect(CLIConnectionFactory.java:72) at hudson.cli.CLI._main(CLI.java:469) at hudson.cli.CLI.main(CLI.java:384)
At the same time the server has already progressed to the following state:
java.lang.Thread.State: RUNNABLE at java.net.SocketInputStream.socketRead0(Native Method) at java.net.SocketInputStream.read(SocketInputStream.java:150) at java.net.SocketInputStream.read(SocketInputStream.java:121) at java.io.FilterInputStream.read(FilterInputStream.java:133) at java.io.FilterInputStream.read(FilterInputStream.java:107) at javax.crypto.CipherInputStream.getMoreData(CipherInputStream.java:103) at javax.crypto.CipherInputStream.read(CipherInputStream.java:224) at java.io.BufferedInputStream.fill(BufferedInputStream.java:235) at java.io.BufferedInputStream.read(BufferedInputStream.java:254) - locked <0x000000041fa9e560> (a java.io.BufferedInputStream) at hudson.remoting.ClassicCommandTransport.create(ClassicCommandTransport.java:98) at hudson.remoting.Channel.<init>(Channel.java:392) at hudson.remoting.Channel.<init>(Channel.java:388) at hudson.cli.CliProtocol$Handler.runCli(CliProtocol.java:48) at hudson.cli.CliProtocol2$Handler2.run(CliProtocol2.java:73) at hudson.cli.CliProtocol2.handle(CliProtocol2.java:32) at hudson.TcpSlaveAgentListener$ConnectionHandler.run(TcpSlaveAgentListener.java:150)
The issue appears to be that the server thinks it has sent the server's identity (CliProtocol2.Handler2.run() line 62) but the client is still waiting for it. The problem is reported as always sporadically reproducible.
I'm failing to reproduce this problem locally. If other people see this problem, please report that here.
- relates to
-
JENKINS-41745 Remoting-free CLI
-
- Resolved
-
Code changed in jenkins
User: Kohsuke Kawaguchi
Path:
core/src/main/java/hudson/cli/CliProtocol2.java
http://jenkins-ci.org/commit/jenkins/2fc99b337af5774c4028e0735de309cfaca78c0a
Log:
suspecting bytes not getting flushed see JENKINS-20709