Skip to content

fix: AsyncQueryResponse's body should be AsyncEsqlResult and not EsqlResult #4257

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Apr 10, 2025

Conversation

pawankartik-elastic
Copy link
Contributor

Based on the documentation here: https://www.elastic.co/guide/en/elasticsearch/reference/current/esql-async-query-api.html#esql-async-query-api-response-body, async query response's body type should be AsyncEsqlResult rather than EsqlResult. This allows accounting for the id and is_running details that are returned by the API.

Copy link
Contributor

Following you can find the validation results for the API you have changed.

API Status Request Response
esql.async_query Missing test Missing test

You can validate this API yourself by using the make validate target.

@pawankartik-elastic pawankartik-elastic merged commit fea1bf8 into main Apr 10, 2025
20 checks passed
@pawankartik-elastic pawankartik-elastic deleted the pkar/async-query-response-body-type-fix branch April 10, 2025 14:02
Copy link
Contributor

The backport to 8.x failed:

The process '/usr/bin/git' failed with exit code 1

To backport manually, run these commands in your terminal:

# Fetch latest updates from GitHub
git fetch
# Create a new working tree
git worktree add .worktrees/backport-8.x 8.x
# Navigate to the new working tree
cd .worktrees/backport-8.x
# Create a new branch
git switch --create backport-4257-to-8.x
# Cherry-pick the merged commit of this pull request and resolve the conflicts
git cherry-pick -x --mainline 1 fea1bf8d8b64746cf69d5dd21412e2d0ee666876
# Push it to GitHub
git push --set-upstream origin backport-4257-to-8.x
# Go back to the original working tree
cd ../..
# Delete the working tree
git worktree remove .worktrees/backport-8.x

Then, create a pull request where the base branch is 8.x and the compare/head branch is backport-4257-to-8.x.

Copy link
Contributor

The backport to 8.17 failed:

The process '/usr/bin/git' failed with exit code 1

To backport manually, run these commands in your terminal:

# Fetch latest updates from GitHub
git fetch
# Create a new working tree
git worktree add .worktrees/backport-8.17 8.17
# Navigate to the new working tree
cd .worktrees/backport-8.17
# Create a new branch
git switch --create backport-4257-to-8.17
# Cherry-pick the merged commit of this pull request and resolve the conflicts
git cherry-pick -x --mainline 1 fea1bf8d8b64746cf69d5dd21412e2d0ee666876
# Push it to GitHub
git push --set-upstream origin backport-4257-to-8.17
# Go back to the original working tree
cd ../..
# Delete the working tree
git worktree remove .worktrees/backport-8.17

Then, create a pull request where the base branch is 8.17 and the compare/head branch is backport-4257-to-8.17.

Copy link
Contributor

The backport to 8.18 failed:

The process '/usr/bin/git' failed with exit code 1

To backport manually, run these commands in your terminal:

# Fetch latest updates from GitHub
git fetch
# Create a new working tree
git worktree add .worktrees/backport-8.18 8.18
# Navigate to the new working tree
cd .worktrees/backport-8.18
# Create a new branch
git switch --create backport-4257-to-8.18
# Cherry-pick the merged commit of this pull request and resolve the conflicts
git cherry-pick -x --mainline 1 fea1bf8d8b64746cf69d5dd21412e2d0ee666876
# Push it to GitHub
git push --set-upstream origin backport-4257-to-8.18
# Go back to the original working tree
cd ../..
# Delete the working tree
git worktree remove .worktrees/backport-8.18

Then, create a pull request where the base branch is 8.18 and the compare/head branch is backport-4257-to-8.18.

github-actions bot pushed a commit that referenced this pull request Apr 10, 2025
l-trotta pushed a commit that referenced this pull request Apr 10, 2025
(cherry picked from commit fea1bf8)

Co-authored-by: Pawan Kartik <[email protected]>
@l-trotta
Copy link
Contributor

took a look at the state of esql.async in the 8.x, 8.18, 8.17 branches and decided not to backport, the main reason we defined async response types is for docs purposes, while clients will handle the result in the generators, so the important thing is that this is in main and 9.0. also we're missing other backports from old PRs, so skipping this backport too.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants