Skip to content

Commit 71ad41e

Browse files
committed
1 parent c4c2210 commit 71ad41e

File tree

1 file changed

+6
-1
lines changed
  • ipfs-api/src/commonMain/kotlin/io/ipfs/kotlin/defaults

1 file changed

+6
-1
lines changed

ipfs-api/src/commonMain/kotlin/io/ipfs/kotlin/defaults/Defaults.kt

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
package io.ipfs.kotlin.defaults
22

33
import io.ktor.client.*
4+
import io.ktor.client.plugins.*
45
import io.ktor.client.plugins.contentnegotiation.*
56
import io.ktor.serialization.kotlinx.json.*
67
import kotlinx.serialization.json.Json
@@ -13,8 +14,12 @@ internal fun createKTOR() = HttpClient {
1314
ignoreUnknownKeys = true
1415
})
1516
}
17+
install(HttpTimeout) {
18+
// this socketTimeout can occur w/ okhttp engine when posting larger file
19+
socketTimeoutMillis = 600_000 // 10 minutes
20+
}
1621
}
1722

18-
expect internal fun createFileSystem() : FileSystem
23+
expect internal fun createFileSystem(): FileSystem
1924

2025

0 commit comments

Comments
 (0)