Skip to content

Commit 6ec775d

Browse files
committed
Fix documentation for timeout parameters
1 parent 2e00b5c commit 6ec775d

File tree

1 file changed

+6
-6
lines changed

1 file changed

+6
-6
lines changed

README.md

+6-6
Original file line numberDiff line numberDiff line change
@@ -260,11 +260,11 @@ Default: false
260260
##### `readTimeout`
261261

262262
```
263-
Type: decimal number
263+
Type: duration
264264
Default: 0
265265
```
266266

267-
I/O read timeout. The value must be a decimal number with an unit suffix ( *"ms"*, *"s"*, *"m"*, *"h"* ), such as *"30s"*, *"0.5m"* or *"1m30s"*.
267+
I/O read timeout. The value must be a decimal number with a unit suffix ( *"ms"*, *"s"*, *"m"*, *"h"* ), such as *"30s"*, *"0.5m"* or *"1m30s"*.
268268

269269
##### `strict`
270270

@@ -283,11 +283,11 @@ By default MySQL also treats notes as warnings. Use [`sql_notes=false`](http://d
283283
##### `timeout`
284284

285285
```
286-
Type: decimal number
286+
Type: duration
287287
Default: OS default
288288
```
289289

290-
*Driver* side connection timeout. The value must be a decimal number with an unit suffix ( *"ms"*, *"s"*, *"m"*, *"h"* ), such as *"30s"*, *"0.5m"* or *"1m30s"*. To set a server side timeout, use the parameter [`wait_timeout`](http://dev.mysql.com/doc/refman/5.6/en/server-system-variables.html#sysvar_wait_timeout).
290+
Timeout for establishing connections, aka dial timeout. The value must be a decimal number with a unit suffix ( *"ms"*, *"s"*, *"m"*, *"h"* ), such as *"30s"*, *"0.5m"* or *"1m30s"*. To configure the duration after which connections are removed from the connection pool, use [*sql.DB.SetConnMaxLifetime](https://golang.org/pkg/database/sql/#DB.SetConnMaxLifetime).
291291

292292
##### `tls`
293293

@@ -302,11 +302,11 @@ Default: false
302302
##### `writeTimeout`
303303

304304
```
305-
Type: decimal number
305+
Type: duration
306306
Default: 0
307307
```
308308

309-
I/O write timeout. The value must be a decimal number with an unit suffix ( *"ms"*, *"s"*, *"m"*, *"h"* ), such as *"30s"*, *"0.5m"* or *"1m30s"*.
309+
I/O write timeout. The value must be a decimal number with a unit suffix ( *"ms"*, *"s"*, *"m"*, *"h"* ), such as *"30s"*, *"0.5m"* or *"1m30s"*.
310310

311311

312312
##### System Variables

0 commit comments

Comments
 (0)