meetings / gearsloth

Gearman job persistence and delayed execution system
MIT License
2 stars 0 forks source link

Crash when connection is lost #86

Open tstarck opened 9 years ago

tstarck commented 9 years ago

Gearsloth crashes (at least in some circumstances) when it loses connection to Gearman server.

Steps to produce:

  1. Connect gearsloth and gearman hosts with ssh tunnel.
  2. Run gearsloth and gearman.
  3. Kill ssh tunnel connecting gearsloth and gearman servers.

    Results:

TypeError: Cannot set property 'connected' of undefined
    at Daemon.setState (/usr/lib/nodejs/gearsloth/lib/daemon/index.js:48:34)
    at Runner.<anonymous> (/usr/lib/nodejs/gearsloth/lib/daemon/index.js:35:9)
    at Runner.EventEmitter.emit (events.js:117:20)
    at Runner.Component._setDisconnected (/usr/lib/nodejs/gearsloth/lib/component.js:162:8)
    at Runner.<anonymous> (/usr/lib/nodejs/gearsloth/lib/component.js:148:12)
    at Runner.EventEmitter.emit (events.js:92:17)
    at Runner.<anonymous> (/usr/lib/nodejs/gearsloth/lib/component.js:128:12)
    at MultiserverClient.EventEmitter.emit (events.js:92:17)
    at MultiserverClient.Multiserver._emitDisconnect (/usr/lib/nodejs/gearsloth/lib/gearman/multiserver.js:38:8)
    at EventEmitter.<anonymous> (/usr/lib/nodejs/gearsloth/lib/gearman/multiserver.js:66:16)