code: public boolean hasToHandleFailover(SQLException exception) {
      return exception.getSQLState() != null
          && (exception.getSQLState().startsWith("08")
          || (exception.getSQLState().equals("70100") && 1927 == exception.getErrorCode()));
    }
docs: Check if this Sqlerror is a connection exception. if that's the case, must be handle by
  failover
  
  <p>error codes : 08000 : connection exception 08001 : SQL client unable to establish SQL
  connection 08002 : connection name in use 08003 : connection does not exist 08004 : SQL server
  rejected SQL connection 08006 : connection failure 08007 : transaction resolution unknown 70100
  : connection was killed if error code is "1927"</p>
  
  @param exception the Exception
  @return true if there has been a connection error that must be handled by failover