### Description

Only "search hits" based queries (no aggregations) provide a consistent view on the data when paginating through the result set. With point-in-time, it is possible to support transactional semantics for aggregation queries as well.

This issue is somewhat blocked by https://github.com/elastic/elasticsearch/issues/75528 because a PIT can not immediately be closed if the aggregation result set contains less than `fetch_size` records. This could cause some increased resource utilization due to open PITs. Especially if the client does not close the SQL cursor.
x-pack/plugin/sql/qa/server/src/main/java/org/elasticsearch/xpack/sql/qa/rest/BaseRestSqlTestCase.java
return "{" + request.toString() + "}";
        }
    }
    protected void index(String... docs) throws IOException {
        indexWithIndexName(TEST_INDEX, docs);
    }
    protected void indexWithIndexName(String indexName, String... docs) throws IOException {
        Request request = new Request("POST", "/" + indexName + "/_bulk");
        request.addParameter("refresh", "true");
        StringBuilder bulk = new StringBuilder();
        for (String doc : docs) {
            bulk.append("""
                {"index":{}}
                %s
                """.formatted(doc));
        }
        request.setJsonEntity(bulk.toString());
        provisioningClient().performRequest(request);
    }
    protected void deleteTestIndex() throws IOException {
        deleteIndex(TEST_INDEX);
    }
    protected static void deleteIndex(String name) throws IOException {
        deleteIndex(provisioningClient(), name);
    }
    public static RequestObjectBuilder query(String query) {
        return RequestObjectBuilder.query(query);
    }
    public static RequestObjectBuilder cursor(String query) {
        return RequestObjectBuilder.cursor(query);