Commit 2e5944d
committed
fix(api): add request timeout and tcp keepalive
The blocking HTTP client was built via reqwest::blocking::Client::new()
with no explicit configuration, which on macOS surfaces as
"error sending request" when a request is in flight long enough for
the OS to drop the quiet TCP connection (e.g. while the server is
doing slow synchronous work like ducklake schema discovery against
a remote catalog).
Add an explicit overall request timeout (5 min) to bound the worst
case if the server genuinely hangs, and a 30s TCP keepalive so the
socket stays warm across long synchronous server work. Both values
live as constants near the helper for clarity.1 parent 20afdfa commit 2e5944d
1 file changed
Lines changed: 23 additions & 2 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
3 | 3 | | |
4 | 4 | | |
5 | 5 | | |
| 6 | + | |
| 7 | + | |
| 8 | + | |
| 9 | + | |
| 10 | + | |
| 11 | + | |
| 12 | + | |
| 13 | + | |
| 14 | + | |
| 15 | + | |
| 16 | + | |
| 17 | + | |
| 18 | + | |
| 19 | + | |
| 20 | + | |
| 21 | + | |
| 22 | + | |
| 23 | + | |
| 24 | + | |
| 25 | + | |
| 26 | + | |
6 | 27 | | |
7 | 28 | | |
8 | 29 | | |
| |||
48 | 69 | | |
49 | 70 | | |
50 | 71 | | |
51 | | - | |
| 72 | + | |
52 | 73 | | |
53 | 74 | | |
54 | 75 | | |
| |||
66 | 87 | | |
67 | 88 | | |
68 | 89 | | |
69 | | - | |
| 90 | + | |
70 | 91 | | |
71 | 92 | | |
72 | 93 | | |
| |||
0 commit comments