0

I have designed scripted pipeline for Jenkins job which does the following steps 1. Creating a property file for running my Angular UI Automation job (Explicitly In Master Jenkins server) 2. Reading property file and run the UI Automation job based on params (Explicitly In Slave Jenkins server - Windows)

Now while in second step i.e in mid of UI Automation job execution , the slave node becomes unresponsive . Log from corresponding job -

F:\RemoteJenkins\workspace\PipelineJobTest\core\zdp-ui>protractor ./e2e/protractor.conf.js --baseUrl=http://192.168.2.9:8080/ui/ ---capabilities.shardTestFiles=true --capabilities.maxInstances=1
[08:39:07] I/launcher - Running 1 instances of WebDriver Cannot contact Windows Slave2: hudson.remoting.RequestAbortedException: java.nio.channels.ClosedChannelException

And Jenkins log says -

un 08, 2020 4:28:27 PM INFO jenkins.slaves.DefaultJnlpSlaveReceiver channelClosed Jetty (winstone)-374996 for Windows Slave2 terminated: java.nio.channels.ClosedChannelException Jun 08, 2020 4:28:34 PM WARNING jenkins.agents.WebSocketAgents$Session error null org.eclipse.jetty.websocket.api.MessageTooLargeException: Binary message size [524494] exceeds maximum size [65536] at org.eclipse.jetty.websocket.api.WebSocketPolicy.assertValidBinaryMessageSize(WebSocketPolicy.java:128) at org.eclipse.jetty.websocket.common.Parser.assertSanePayloadLength(Parser.java:133) at org.eclipse.jetty.websocket.common.Parser.parseFrame(Parser.java:494) at org.eclipse.jetty.websocket.common.Parser.parseSingleFrame(Parser.java:253) at org.eclipse.jetty.websocket.common.io.AbstractWebSocketConnection.onFillable(AbstractWebSocketConnection.java:460) at org.eclipse.jetty.websocket.common.io.AbstractWebSocketConnection.onFillable(AbstractWebSocketConnection.java:441) at org.eclipse.jetty.io.AbstractConnection$ReadCallback.succeeded(AbstractConnection.java:311) at org.eclipse.jetty.io.FillInterest.fillable(FillInterest.java:103) at org.eclipse.jetty.io.ChannelEndPoint$2.run(ChannelEndPoint.java:117) at org.eclipse.jetty.util.thread.strategy.EatWhatYouKill.runTask(EatWhatYouKill.java:336) at org.eclipse.jetty.util.thread.strategy.EatWhatYouKill.doProduce(EatWhatYouKill.java:313) at org.eclipse.jetty.util.thread.strategy.EatWhatYouKill.tryProduce(EatWhatYouKill.java:171) at org.eclipse.jetty.util.thread.strategy.EatWhatYouKill.run(EatWhatYouKill.java:129) at org.eclipse.jetty.util.thread.ReservedThreadExecutor$ReservedThread.run(ReservedThreadExecutor.java:375) at org.eclipse.jetty.util.thread.QueuedThreadPool.runJob(QueuedThreadPool.java:806) at org.eclipse.jetty.util.thread.QueuedThreadPool$Runner.run(QueuedThreadPool.java:938) at java.lang.Thread.run(Thread.java:748)

user1916693
  • 125
  • 2
  • 7
  • Are your Master and slave on same JAVA version? – Ayush Gupta Jun 08 '20 at 16:33
  • Does this answer your question? [Jenkins Windows slave connection getting terminated with java.nio.channels.ClosedChannelException](https://stackoverflow.com/questions/45433225/jenkins-windows-slave-connection-getting-terminated-with-java-nio-channels-close) – Ayush Gupta Jun 08 '20 at 16:37
  • Previously it was not but I tried making it same version but faced with same issue again. Both master and slave have version - openjdk version "1.8.0_252" – user1916693 Jun 08 '20 at 16:38

1 Answers1

0

Finally after lot of experiment I found the solution

Solution 1 : This is happening as websocket is getting crashed . So instead of writing to Jenkins console , redirect the job output to some file .

Solution 2 : Secondly this is an issue with Jenkins ver. 2.227 . The fix for this issue is released on Jenkins 2.229 as per https://issues.jenkins-ci.org/browse/JENKINS-61409

user1916693
  • 125
  • 2
  • 7