Skip to content

Commit

Permalink
docs: document PoolCluster disconnect behavior
Browse files Browse the repository at this point in the history
closes #2224
  • Loading branch information
datvong-wm authored and dougwilson committed Jan 21, 2020
1 parent d247eef commit ec382a2
Showing 1 changed file with 7 additions and 0 deletions.
7 changes: 7 additions & 0 deletions Readme.md
Original file line number Diff line number Diff line change
Expand Up @@ -650,6 +650,13 @@ terminated, an existing connection object cannot be re-connected by design.
With Pool, disconnected connections will be removed from the pool freeing up
space for a new connection to be created on the next getConnection call.

With PoolCluster, disconnected connections will count as errors against the
related node, incrementing the error code for that node. Once there are more than
`removeNodeErrorCount` errors on a given node, it is removed from the cluster.
When this occurs, the PoolCluster may emit a `POOL_NONEONLINE` error if there are
no longer any matching nodes for the pattern. The `restoreNodeTimeout` config can
be set to restore offline nodes after a given timeout.

## Performing queries

The most basic way to perform a query is to call the `.query()` method on an object
Expand Down

0 comments on commit ec382a2

Please sign in to comment.