Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Grammar updates to api.md #190

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 3 additions & 3 deletions docs/api.md
Original file line number Diff line number Diff line change
Expand Up @@ -24,13 +24,13 @@
cluster('app')
.listen(3000);

A good example if this, is a long-lived database connection. Our _app.js_ may have this initialized at the top, which although will work fine stand-alone, may cause cluster's master processes to hang when restarting or closing due to the connection remaining active in the event loop.
A good example of this is a long-lived database connection. Our _app.js_ may have this initialized at the top, which will work fine stand-alone, but may cause a cluster's master process to hang when restarting or closing due to the connection remaining active in the event loop.

var db = redis.createClient();

### Abstract Clusters

Cluster is not bound to servers, cluster can be used to manage processes for processing job queues etc. Below is a minimalist example of this, simply invokes `cluster()` with no object, spawning a worker per cpu:
Cluster is not bound to servers; cluster can be used to manage processes for processing job queues, etc. Below is a minimalist example of this, simply invokes `cluster()` with no object, spawning a worker per cpu:

var cluster = require('cluster');

Expand Down Expand Up @@ -213,4 +213,4 @@

### Master#kill([signal])

Sends __SIGTERM__ or `signal` to all worker processes. This method is used by `Master#restart()`, `Master#close()` etc.
Sends __SIGTERM__ or `signal` to all worker processes. This method is used by `Master#restart()`, `Master#close()` etc.