### Description

We need to make sure we capture the exceptions leading to a non-successful response to the user.
These should capture any other wrapped exceptions.
Depending on the cause, they should be log warnings or errors.
x-pack/plugin/esql/src/main/java/org/elasticsearch/xpack/esql/action/EsqlResponseListener.java
restResponse.addHeader(HEADER_NAME_TOOK_NANOS, Long.toString(tookNanos));
            success = true;
            return restResponse;
        } finally {
            if (success == false) {
                esqlResponse.close();
            }
        }
    }
    /**
     * Log the execution time and query when handling an ES|QL response.
     */
    public ActionListener<EsqlQueryResponse> wrapWithLogging() {
        return ActionListener.wrap(r -> {
            onResponse(r);
            
            LOGGER.info(
                "Finished execution of ESQL query.\nQuery string: [{}]\nExecution time: [{}]ms",
                esqlQuery,
                stopWatch.stop().getMillis()
            );
        }, ex -> {
            
            long timeMillis = stopWatch.stop().getMillis();
            onFailure(ex);
            LOGGER.info("Failed execution of ESQL query.\nQuery string: [{}]\nExecution time: [{}]ms", esqlQuery, timeMillis);
        });
    }
}