Unhandled rejection Error [ERR_IPC_CHANNEL_CLOSED]: channel closed #1
Loading…
Reference in New Issue
No description provided.
Delete Branch "%!s(<nil>)"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Node Version: v10.15.1
greenlock-cluster@2.1.0
Note: This only occurs after the process has been idle for hours.
Also occurring in Node Version v8.15.0
Ok. This is a possible false alarm. Found evidence that my children are exiting unexpectedly. I'll need to cleanup the opts._workers array to keep things current.
This small addition to my code solves the issue for me.
And its necessary as greenlock-cluster/master.js creates an array of workers via the addWorker method (line #26). If those workers die or get killed externally for any reason then the attempt to broadcast to all of them on line #80 fails with ERR_IPC_CHANNEL_CLOSED.
FYI: as an optimization, it may be simpler to rely on the hash of active workers provided by the cluster module.
https://nodejs.org/dist/latest-v10.x/docs/api/cluster.html#cluster_cluster_workers
Otherwise, adding the code above to the documentation would be helpful to new users relying on this module.