Skip to content

Commit b062c50

Browse files
authored
Merge pull request #201 from mdouchin/patch-1
Add more example for timeouts
2 parents e925600 + 31e5d16 commit b062c50

1 file changed

Lines changed: 13 additions & 1 deletion

File tree

README.md

Lines changed: 13 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -339,7 +339,19 @@ SET http.curlopt_tcp_keepalive = 1;
339339
By default a 5 second timeout is set for the completion of a request. If a different timeout is desired the following GUC variable can be used to set it in milliseconds:
340340

341341
```sql
342-
SET http.curlopt_timeout_msec = 200;
342+
SET http.curlopt_timeout_ms = 200;
343+
```
344+
345+
You can also change the timeout for the connection, to avoid waiting for too long when a service is unavailable:
346+
347+
```sql
348+
SET http.curlopt_connecttimeout_ms = 100;
349+
```
350+
351+
When a timeout occurs during a request, a SQL error will be raised:
352+
353+
```sql
354+
ERROR: Operation timed out after 200 milliseconds with 0 bytes received
343355
```
344356

345357
## Installation

0 commit comments

Comments
 (0)