express-server-cluster

    3.0.0 • Public • Published

    express-server-cluster

    Create a clustered express server

    build status

    Installation

    npm install express-server-cluster --save
    

    Usage

    var express = require('express')
      , server = express()
      , createServerCluster = require('express-server-cluster')
      , options =
        { port: 5678
        , numProcesses: 1
        }
    
    server.on('started', function (server) {
      console.log('server started on: ' + server.address().port)
    })
    
    server.on('requestError', function (error, req) {
      console.error('request error: ' + error.message + ': ' + req.url)
    })
    
    createServerCluster(server, console, options)
    
    

    Credits

    Adam Duncan

    Keywords

    none

    Install

    npm i express-server-cluster

    DownloadsWeekly Downloads

    43

    Version

    3.0.0

    License

    ISC

    Last publish

    Collaborators

    • microadam