{"_id":"cluster-manager","_rev":"12-71611e6b47b9e4efcb63a1434391c096","name":"cluster-manager","description":"Manage cluster applications with email alerting on crash of worker","dist-tags":{"latest":"0.1.0"},"versions":{"0.0.1":{"name":"cluster-manager","version":"0.0.1","description":"Manage cluster applications with email alerting on crash of worker","main":"ClusterManager.js","scripts":{"test":"echo \"Error: no test specified\" && exit 1"},"repository":{"type":"git","url":"git@github.com:holidayextras/cluster-manager.git"},"keywords":["stream","express","connect","rotate","file"],"author":{"name":"Roger Castells"},"license":"MIT","_id":"cluster-manager@0.0.1","dist":{"shasum":"b9663596ae7c3e1ea2adb6cd9958506140a0956d","tarball":"https://registry.npmjs.org/cluster-manager/-/cluster-manager-0.0.1.tgz","integrity":"sha512-F8zlqQIcUGUAPAzG5Zv+tWSzOZGoJ3CeNPHIGIy8q95mZyvxrum1nrod//+6q5+pEd7wXTJDfp+qYkojSDfi7g==","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEQCIC2WSQlq2GlXUriyVX9d4sWWVBn083K81Mq0OJAboFn1AiBjAtGZ6YICbeMObmRp8SSycTi1Fhl3ZmSyG9Ic1lAfnw=="}]},"_npmVersion":"1.1.63","_npmUser":{"name":"viktort","email":"viktor.trako@gmail.com"},"maintainers":[{"name":"viktort","email":"viktor.trako@gmail.com"}]},"0.0.2":{"name":"cluster-manager","version":"0.0.2","description":"Manage cluster applications with email alerting on crash of worker","main":"ClusterManager.js","scripts":{"test":"echo \"Error: no test specified\" && exit 1"},"repository":{"type":"git","url":"git@github.com:holidayextras/cluster-manager.git"},"keywords":["stream","express","connect","rotate","file"],"author":{"name":"Roger Castells"},"license":"MIT","_id":"cluster-manager@0.0.2","dist":{"shasum":"d1957b59f882989095b7b0f6d0aa98f6d40770c0","tarball":"https://registry.npmjs.org/cluster-manager/-/cluster-manager-0.0.2.tgz","integrity":"sha512-lJzvdOwHKZwSuwtesrFiXdljg912HU+TE81jwJKfvqu8fQVArGpXQGAVMiOrE6RPtC52hKMJoFqQmWLt15oLOQ==","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIE2DbfMrxmB+AcO1BylPc2ishXSisfDGMvWuXVd+Sh4CAiEA7N7vM+3i5s72NZxlZ63r+uQ9psqXwBQI0g/Dt5KmOko="}]},"_npmVersion":"1.1.63","_npmUser":{"name":"viktort","email":"viktor.trako@gmail.com"},"maintainers":[{"name":"viktort","email":"viktor.trako@gmail.com"},{"name":"rogerc","email":"rogerc@ataclick.net"}]},"0.1.0":{"name":"cluster-manager","version":"0.1.0","description":"Manage cluster applications with email alerting on crash of worker","main":"ClusterManager.js","scripts":{"test":"echo \"Error: no test specified\" && exit 1","lint":"make-up && echo 'Linting: ✓'"},"repository":{"type":"git","url":"git+ssh://git@github.com/holidayextras/cluster-manager.git"},"keywords":["cluster","notification"],"author":{"name":"Holiday Extras","email":"sas+npm@holidayextras.com"},"license":"MIT","devDependencies":{"make-up":"6.0.0"},"gitHead":"2fba478cbfe89761c96b5e389e67b2afa01f5f7e","bugs":{"url":"https://github.com/holidayextras/cluster-manager/issues"},"homepage":"https://github.com/holidayextras/cluster-manager#readme","_id":"cluster-manager@0.1.0","_shasum":"2b80532601b88923316f8738665e5e02294cfae8","_from":".","_npmVersion":"2.14.12","_nodeVersion":"4.2.4","_npmUser":{"name":"hx-pedro-romano","email":"pedro.romano@holidayextras.com"},"maintainers":[{"name":"holidayextras","email":"sas+npm@holidayextras.com"},{"name":"hx-pedro-romano","email":"pedro.romano@holidayextras.com"},{"name":"viktort","email":"viktor.trako@holidayextras.com"}],"dist":{"shasum":"2b80532601b88923316f8738665e5e02294cfae8","tarball":"https://registry.npmjs.org/cluster-manager/-/cluster-manager-0.1.0.tgz","integrity":"sha512-aiCvb9I6Av4xQ/aQhGCzdrTmzsuFeLk8yUn2ZeRwivNVTKQbr7shLaN2vSZ1Hhk55vw1tHWdFbY+nj/k8ZqG5g==","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEQCIHtKZa0sDdNwCDjT1lkm438PjLPnXCyMNB1Lfb1F2iqLAiBcaZxWEbOiFA0Ed7sm2lAILw5p5gTAXbxtowZiBT5brw=="}]}}},"readme":"cluster-manager\n===============\n\n## Purpose\n\nTo manage apps that want to use nodejs cluster module. This module will restart workers on failure and allows rolling restarts. It can send email notifications on worker failure.\n\n## Install\n\n```bash\nnpm install -g cluster-manager\n```\n\n## Usage\n```node\nvar clusterManager = require('cluster-manager');\n\nclusterManager({\n    exec:\"/PATH/TO/APPLICATION\",\n    workers: 5,\n    notify:{\n        from:\"from@address.com\",\n        to:\"recipient@address.com\",\n        subjectPrefix:\"SUBJECT PREFIX\"\n    }\n});\n```\n## Options\n\nBelow are the keys that can be set in the JSON object. They are all optional except for __exec__.\n\n<dl>\n    <dt>exec</dt>\n    <dd>node application that will be started by the cluster</dd>\n\n    <dt>workers</dt>\n    <dd>number of workers that will be spawned. Default:2</dd>\n\n    <dt>pidfile</dt>\n    <dd>File to store the ID for the main process. Used to send signals to the cluster manager</dd>\n\n    <dt>notify</dt>\n    <dd>Object with a <i>from</i>, <i>to</i> and <i>subjectPrefix</i> property. If set, the recipient will receive email notifications on events that affect the workers. To send notifications, it requires __/usr/lib/sendmail__.</dd>\n\n    <dt>verbose</dt>\n    <dd>Handles if the cluster-manager will be verbose in its messages. Default:false</dd>\n\n    <dt>silent</dt>\n    <dd>Determines if the worker stdout streams are silent. Default:false</dd>\n\n    <dt>env</dt>\n    <dd>Object with the environment variables passed on to the workers</dd>\n\n    <dt>waitBeforeShutdown</dt>\n    <dd>How long to wait after reloading workers to confirm reload was successful. After this time, the old workers will be shut down.</dd>\n\n    <dt>waitBeforeForceQuit</dt>\n    <dd>How long to wait before the cluster manager will force a worker to shutdown after the initial shutdown request</dd>\n</dl>\n\n## Signals\n\nWhile the cluster manager is running, you can send signals.\n\n*To reload workers - start new ones and shut down the old ones.\n\n> kill -HUP MASTERPID\n\n*To output to stdout number of workers and their PIDs\n\n> kill -USR1 MASTERPID\n\n*To increase running workers to the maximum number set at the start\n\n> kill -USR2 MASTERPID\n\n*To attempt graceful shutdown\n\n> kill -TERM MASTERPID\n\n\n## NPM Maintainers\n\nThe npm module for this library is maintained by:\n\n* [Roger Castells](http://github.com/rogerc)\n* [Viktor Trako](http://github.com/viktort)\n* [Dan Jenkins](http://github.com/danjenkins)\n\n## License\n\ncluster-manager is licensed under the MIT license.","maintainers":[{"name":"holidayextras","email":"sas+npm@holidayextras.com"},{"name":"hx-pedro-romano","email":"pedro.romano@holidayextras.com"},{"name":"viktort","email":"viktor.trako@holidayextras.com"}],"time":{"modified":"2022-06-13T06:17:40.600Z","created":"2012-11-14T14:43:11.223Z","0.0.1":"2012-11-14T14:43:13.416Z","0.0.2":"2012-11-14T16:24:32.621Z","0.1.0":"2016-01-08T12:13:00.029Z"},"author":{"name":"Holiday Extras","email":"sas+npm@holidayextras.com"},"repository":{"type":"git","url":"git+ssh://git@github.com/holidayextras/cluster-manager.git"},"keywords":["cluster","notification"],"license":"MIT","readmeFilename":"README.md","homepage":"https://github.com/holidayextras/cluster-manager#readme","bugs":{"url":"https://github.com/holidayextras/cluster-manager/issues"}}