8000 Notes about pause / resume · mysqljs/mysql@ccf4b19 · GitHub
[go: up one dir, main page]

Skip to content

Commit ccf4b19

Browse files
committed
Notes about pause / resume
1 parent 5e51c94 commit ccf4b19

File tree

1 file changed

+8
-0
lines changed

1 file changed

+8
-0
lines changed

Readme.md

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -204,6 +204,14 @@ query
204204
});
205205
```
206206

207+
Please note a few things about the example above:
208+
209+
* Usually you will want to receive a certain amount of rows before starting to
210+
throttle the connection using `pause()`. This number will depend on the
211+
amount and size of your rows.
212+
* `pause()` / `resume()` operate on the underlaying socket and parser. You are
213+
guaranteed that no more `'row'` events will fire after calling `pause()`.
214+
207215
## Error Handling
208216

209217
This module comes with a consistent approach to error handling that you should

0 commit comments

Comments
 (0)
0