Github user WangTaoTheTonic commented on the pull request:
https://github.com/apache/spark/pull/5116#issuecomment-97285108
>I believe we will never throw this exception outside of readResponse
No. In `postJson`, it will throw a `ConnectException` when try to get
output stream of a connection while the remote server is down. I take care of
it here:
>try {
val out = new DataOutputStream(conn.getOutputStream)
Utils.tryWithSafeFinally {
out.write(json.getBytes(Charsets.UTF_8))
} {
out.close()
}
} catch {
case e: ConnectException =>
throw new SubmitRestConnectionException("Connect Exception when
connect to server", e)
}
---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at [email protected] or file a JIRA ticket
with INFRA.
---
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]