Use case: Customer is using a cloud based solution as their email server. Email Engine is configured to fetch emails from the mailserver via SSL connection.
Recently some problem caused the SSL handshake to hang in the ClientHello and the email engine waited for continuation forever.
This essentially caused the email engine to hang and not fetch mails until it got restarted.
The steps to troubleshoot the "hang" of the email engine were quite extensive and identfiying the cause of the hang took some time.
Therefore it would be great if the email engine would implement a nonzero sockettimeout as described in eg.
public void setSoTimeout(int timeout) throws SocketException
SO_TIMEOUT with the specified timeout, in milliseconds. With this option set to a non-zero timeout, a read() call on the InputStream associated with this Socket will block for only this amount of time. If the timeout expires, a java.net.SocketTimeoutException is raised, though the Socket is still valid. The option must be enabled prior to entering the blocking operation to have effect. The timeout must be
> 0. A timeout of zero is interpreted as an infinite timeout.
timeout- the specified timeout, in milliseconds.
SocketException- if there is an error in the underlying protocol, such as a TCP error