bmoers / sn-cicd

CICD Server for Service-Now
GNU Lesser General Public License v3.0
44 stars 36 forks source link

worker node running status should change to pause when job done #2

Closed gitlabbin closed 5 years ago

gitlabbin commented 5 years ago
 - the worker clientState need to be `pause`

Fix for issue #1

@bmoers ,please review it, if it is right way to fix.

bmoers commented 5 years ago

Correct, that's a bug. I agree with 7e4805e, so it will run() again and use the existing proc to set the worker on pause. But cant agree with 2b7ce26. Why was socket.emit('paused') added? And the reconnectionAttempts != Infinity will require a worker restart in case the server is down for longer.

gitlabbin commented 5 years ago

@bmoers , you are right, I should not include 2b7ce26, which is some code I tried to fix 100% cpu, roll back to previous fix now.

bmoers commented 5 years ago

Thanks. There is a known bug with Node 11.0.0 https://github.com/nodejs/node/issues/23860