-
Notifications
You must be signed in to change notification settings - Fork 8.5k
Description
Describe the feature:
ES us working on a task https://elasticco.atlassian.net/browse/ES-8808 which would enable interrupting ES|QL async query and getting the results on demand. The targeted use case is for the client - like Kibana - upon detecting that the async request takes too long, send POST /_query/async//stop and collect the results (stop command would return the same result as async get, but it will guarantee the completed result - or failure, of course). Note that this is completely client-driven - the client decides when it's time to issue stop request, as ES|QL currently has no built-in timeouts. If the query finishes by the time stop request is issued, it works the same as _async/get i.e. you get the result of the query.
In the unified search we give the users the ability to cancel the request. We could instead change the implementation and instead of cancelling, use the new api and stop the query. With that way the users can get back partial results instead of emty.
The same logic we have after a timeout. We cancel the request and we dont show the partial results. We could also change the implementation and use the new api.
Discover should show that these are partial results (the team told me that there are already indicators as this works already like that in the dataview mode.