-
Notifications
You must be signed in to change notification settings - Fork 24.7k
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
high level REST client allows for a wrong operation with scroll API #44493
Comments
Pinging @elastic/es-core-features |
You are correct @9deniz , as per 4ff12c9, this is not possible. Maybe @cbuescher can shed some light here if more questions are had by @domer-sz on the subject. Also, thank you for helping triage this @9deniz, I totally missed that this is the case when I read over it! |
Hey, I understand the exception is expected in this situation. The purpose of my request was to make sure you can't design an api in such a way that you can't create a request that won't be executed correctly in runtime. |
Pinging @elastic/es-search |
@domer-sz ok thats perfectly acceptable. I will relabel it so it does not pertain to the high level rest client, and instead let the proper people know. Ill also edit the issue a bit so its more descriptive to search |
Actually I misread your point at first, ill remove the search label :) Let me see if its possible to do that with this API currently, since its a generic API that many things can be added to. |
This commit builds on elastic#26235, and adds the same validation to the builder so that it will throw an exception when setting a scroll on a request that has from set. Relates elastic#9373 Closes elastic#44493
We have decided to close this issue for now without merging and will revisit it once the high level rest client has its own pojos and builders. This is something we will be doing down the road, but we dont have a timeframe on when it will be finished. |
Feature request -->
High level REST client allows you to set the .from option in SearchSourceBuilder when using SearchScrollRequest but that return ActionRequestValidationException on runtime. The feature request is an api fix so that it does not allow to build a query that will not pass the validation in the runtime.
Example of code that throw ActionRequestValidationException
The text was updated successfully, but these errors were encountered: