Minimal HTTP fetch helpers with connect/read timeouts.
java.net.URL/openStream has no timeouts, so a stalled transfer
(e.g. the ECB rates endpoint freezing mid-download) blocks the calling
thread forever. Every network fetch in ecbjure goes through here instead.
Minimal HTTP fetch helpers with connect/read timeouts. `java.net.URL/openStream` has no timeouts, so a stalled transfer (e.g. the ECB rates endpoint freezing mid-download) blocks the calling thread forever. Every network fetch in ecbjure goes through here instead.
Max milliseconds to wait for the connection to be established. Rebind to override.
Max milliseconds to wait for the connection to be established. Rebind to override.
Max milliseconds to wait on a single read before treating the transfer as stalled. Rebind to override.
Max milliseconds to wait on a single read before treating the transfer as stalled. Rebind to override.
(fetch-bytes url-str)Fetch url-str fully into a byte array, with timeouts.
Fetch url-str fully into a byte array, with timeouts.
(open-stream url-str)Open an InputStream on url-str with connect/read timeouts applied. Throws java.net.SocketTimeoutException if connecting or a read stalls.
Open an InputStream on url-str with connect/read timeouts applied. Throws java.net.SocketTimeoutException if connecting or a read stalls.
cljdoc builds & hosts documentation for Clojure/Script libraries
| Ctrl+k | Jump to recent docs |
| ← | Move to previous article |
| → | Move to next article |
| Ctrl+/ | Jump to the search field |