-
Notifications
You must be signed in to change notification settings - Fork 180
[BugFix] Prevent push down limit with offset reach maxResultWindow #3713
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
Changes from 1 commit
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,53 @@ | ||
| setup: | ||
| - skip: | ||
| features: | ||
| - headers | ||
| - do: | ||
| indices.create: | ||
| index: test | ||
| body: | ||
| settings: | ||
| max_result_window: 1 | ||
| - do: | ||
| bulk: | ||
| index: test | ||
| refresh: true | ||
| body: | ||
| - '{"index": {}}' | ||
| - '{"id": 1}' | ||
| - '{"index": {}}' | ||
| - '{"id": 2}' | ||
| - '{"index": {}}' | ||
| - '{"id": 3}' | ||
|
|
||
|
|
||
| --- | ||
| teardown: | ||
| - do: | ||
| query.settings: | ||
| body: | ||
| transient: | ||
| plugins.calcite.enabled : false | ||
| plugins.calcite.fallback.allowed : true | ||
|
||
|
|
||
| --- | ||
| "Prevent push down limit if the offset exceeds max_result_window": | ||
| - do: | ||
| headers: | ||
| Content-Type: 'application/json' | ||
| ppl: | ||
| body: | ||
| query: 'source=test | head 1 from 1 ' | ||
| - match: {"total": 1} | ||
| - match: {"schema": [{"name": "id", "type": "bigint"}]} | ||
| - match: {"datarows": [[2]]} | ||
|
|
||
| - do: | ||
| headers: | ||
| Content-Type: 'application/json' | ||
| ppl: | ||
| body: | ||
| query: 'source=test | head 2 | head 1 from 1 ' | ||
| - match: { "total": 1 } | ||
| - match: { "schema": [ { "name": "id", "type": "bigint" } ] } | ||
| - match: { "datarows": [ [ 2 ] ] } | ||
|
Member
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. what's the result without this fixing? |
||
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
nit, no need revert setting, by default is disabled