mirror of
https://github.com/corda/corda.git
synced 2025-03-23 04:25:19 +00:00
Increased timeout time for reads during HTTP connections to avoid demo failing when date it set far in the future.
This commit is contained in:
parent
609d80e630
commit
21dc8e7fd4
@ -346,7 +346,7 @@ private fun sendJson(url: URL, data: String, method: String) : Boolean {
|
||||
connection.useCaches = false
|
||||
connection.requestMethod = method
|
||||
connection.connectTimeout = 5000
|
||||
connection.readTimeout = 15000
|
||||
connection.readTimeout = 60000
|
||||
connection.setRequestProperty("Connection", "Keep-Alive")
|
||||
connection.setRequestProperty("Cache-Control", "no-cache")
|
||||
connection.setRequestProperty("Content-Type", "application/json")
|
||||
@ -391,7 +391,7 @@ private fun uploadFile(url: URL, file: String) : Boolean {
|
||||
connection.useCaches = false
|
||||
connection.requestMethod = "POST"
|
||||
connection.connectTimeout = 5000
|
||||
connection.readTimeout = 5000
|
||||
connection.readTimeout = 60000
|
||||
connection.setRequestProperty("Connection", "Keep-Alive")
|
||||
connection.setRequestProperty("Cache-Control", "no-cache")
|
||||
connection.setRequestProperty("Content-Type", "multipart/form-data; boundary=" + boundary)
|
||||
|
Loading…
x
Reference in New Issue
Block a user