Skip to content

Commit 717046d

Browse files
committed
documentation: add description of conn:close() and pool:close() methods
1 parent 54e54e0 commit 717046d

File tree

1 file changed

+13
-0
lines changed

1 file changed

+13
-0
lines changed

README.md

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -170,6 +170,13 @@ Quote a query string.
170170
- `quoted_string` on success
171171
- `error(reason)` on error
172172

173+
### `conn:close()`
174+
175+
Close the individual connection or return it to a pool.
176+
Throws an error on failure.
177+
178+
*Returns*: `true`
179+
173180
### `pool = mysql.pool_create(opts)`
174181

175182
Create a connection pool with count of size established connections.
@@ -216,6 +223,12 @@ Return a connection to connection pool.
216223

217224
- `conn` - a connection
218225

226+
### `pool:close()`
227+
228+
Close all connections in pool.
229+
230+
*Returns*: `true`
231+
219232
## Comments
220233

221234
All calls to connections api will be serialized, so it should to be safe to

0 commit comments

Comments
 (0)