Skip to content
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

Internal Query: Adds adoption of pagination lib #1812

Merged
merged 107 commits into from Oct 7, 2020

Conversation

bchong95
Copy link
Contributor

Internal Query: Adds adoption of pagination lib

Description

This code migrates the query code to use the new pagination lib. Everything is now part of a query pipeline, which is shown in the QueryPipelineStage class. Some internal benefits is that this code is now fully exceptionless and one ExecuteNextAsync call will correspond to a single fetch of a backend page. This was possible by reworking ORDER BY to have state similar to GROUP BY. At the beginning MoveNext will trigger a single item producer to fetch from the backend and move that item producer from an uninitalized to initalized state. We stall the pipeline back returning an empty page with the corresponding query metrics. This makes the pipeline more responsive and we can handle exceptions easier.

For testing all the pipeline stages are now fully testable without the need for an emulator and with the addition of a query parser and offline engine we are able to run full end to end queries without the need of an emulator for testing.

Copy link
Member

@FabianMeiswinkel FabianMeiswinkel left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM - only significant cmment/question is around the Reflection usage in Microsoft.Azure.Cosmos/src/Pagination/Record.cs

@ghost
Copy link

ghost commented Dec 15, 2021

Closing due to in-activity, pease feel free to re-open.

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

Successfully merging this pull request may close these issues.

None yet

4 participants