[SPARK-4260] Httpbroadcast should set connection timeout.
Httpbroadcast sets read timeout but doesn't set connection timeout. Author: Kousuke Saruta <sarutak@oss.nttdata.co.jp> Closes #3122 from sarutak/httpbroadcast-timeout and squashes the following commits: c7f3a56 [Kousuke Saruta] Added Connection timeout for Http Connection to HttpBroadcast.scala
This commit is contained in:
parent
861223ee5b
commit
60969b0336
|
@ -191,10 +191,12 @@ private[broadcast] object HttpBroadcast extends Logging {
|
|||
logDebug("broadcast security enabled")
|
||||
val newuri = Utils.constructURIForAuthentication(new URI(url), securityManager)
|
||||
uc = newuri.toURL.openConnection()
|
||||
uc.setConnectTimeout(httpReadTimeout)
|
||||
uc.setAllowUserInteraction(false)
|
||||
} else {
|
||||
logDebug("broadcast not using security")
|
||||
uc = new URL(url).openConnection()
|
||||
uc.setConnectTimeout(httpReadTimeout)
|
||||
}
|
||||
|
||||
val in = {
|
||||
|
|
Loading…
Reference in a new issue