Should it be <code>  if (e.getCause() != null && e.getCause().getCause() != null && e.getCause().getCause() instanceof SSLHandshakeException) </code>