### CI Link

https://gradle-enterprise.elastic.co/s/vgdjkeiiridsk/tests/:x-pack:plugin:sql:qa:mixed-node:v8.2.0%23mixedClusterTest/org.elasticsearch.xpack.sql.qa.mixed_node.SqlCompatIT/testCursorFromOldNodeFailsOnNewNode?top-execution=1

### Repro line

./gradlew ':x-pack:plugin:sql:qa:mixed-node:v8.2.0#mixedClusterTest' -Dtests.class="org.elasticsearch.xpack.sql.qa.mixed_node.SqlCompatIT" -Dtests.method="testCursorFromOldNodeFailsOnNewNode" -Dtests.seed=FDCF684F324DE11D -Dtests.bwc=true -Dtests.locale=es-PR -Dtests.timezone=Asia/Baku -Druntime.java=17

### Does it reproduce?

Yes

### Applicable branches

master

### Failure history

_No response_

### Failure excerpt

```
java.lang.AssertionError:
  Expected: a string containing "Unsupported cursor version [8.2.0], expected [8.3.0]" |  
  but: was "method [POST], host [http://127.0.0.1:34941], URI [_sql], status line [HTTP/1.1 500 Internal Server Error] |  
  {"error":{"root_cause":[{"type":"sql_illegal_argument_exception","reason":"Unsupported cursor version [1.66.82], expected [8.3.0]"}],"type":"sql_illegal_argument_exception","reason":"Unsupported cursor version [1.66.82], expected [8.3.0]"},"status":500}"
```

x-pack/plugin/sql/qa/mixed-node/src/test/java/org/elasticsearch/xpack/sql/qa/mixed_node/SqlCompatIT.java
assertEquals(200, response.getStatusLine().getStatusCode());
        try (InputStream content = response.getEntity().getContent()) {
            return XContentHelper.convertToMap(JsonXContent.jsonXContent, content, false);
        }
    }
    public void testCreateCursorWithFormatTxtOnNewNode() throws IOException {
        testCreateCursorWithFormatTxt(newNodesClient);
    }
    public void testCreateCursorWithFormatTxtOnOldNode() throws IOException {
        testCreateCursorWithFormatTxt(oldNodesClient);
    }
    /**
     * Tests covering https://github.com/elastic/elasticsearch/issues/83581
     */
    public void testCreateCursorWithFormatTxt(RestClient client) throws IOException {
        index("{\"foo\":1}", "{\"foo\":2}");
        Request query = new Request("POST", "_sql");
        XContentBuilder json = XContentFactory.jsonBuilder()
            .startObject()
            .field("query", randomFrom("SELECT foo FROM test", "SELECT foo FROM test GROUP BY foo"))
            .field("fetch_size", 1)
            .endObject();
        query.setJsonEntity(Strings.toString(json));
        query.addParameter("format", "txt");
        Response response = client.performRequest(query);
        assertOK(response);
        assertFalse(Strings.isNullOrEmpty(response.getHeader("Cursor")));
    }
}