@Override
    public QueryException createException(Optional<QueryStats> queryStats, SQLException cause)
    {
        Optional<Throwable> clusterConnectionExceptionCause = getClusterConnectionExceptionCause(cause);
        if (clusterConnectionExceptionCause.isPresent()) {
            return QueryException.forClusterConnection(clusterConnectionExceptionCause.get());
        }

        Optional<ErrorCodeSupplier> errorCode = Optional.ofNullable(errorByCode.get(cause.getErrorCode()));
        return QueryException.forPresto(cause, errorCode, queryStats);
    }
@Test
    public void testUnknownPrestoException()
    {
        SQLException sqlException = new SQLException("", "", 0xabcd_1234, new RuntimeException());
        assertQueryException(
                classifier.createException(Optional.of(QUERY_STATS), sqlException),
                PRESTO,
                Optional.empty(),
                Optional.of(QUERY_STATS));
    }