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

Split queries for defer directive #1177

Closed
wants to merge 6 commits into from
Closed

Split queries for defer directive #1177

wants to merge 6 commits into from

Conversation

bnjjj
Copy link
Contributor

@bnjjj bnjjj commented Jun 2, 2022

Related to #80
Fix #1178

  • Split main query into primary and deferred queries
  • Rewrite the InlineFragment implementation
  • Add support of static check for @include and @skip directives

The query is split regarding the @defer directive. If we could statically detect that the selection will be deferred then we just skip it from the primary selection. If not we will clone the selection into deferred_queries and also keep it in the primary query to be able to detect at the execution stage if it's a deferred selection or not.

bnjjj added 6 commits June 2, 2022 11:17
Signed-off-by: Benjamin Coenen <5719034+bnjjj@users.noreply.github.com>
Signed-off-by: Benjamin Coenen <5719034+bnjjj@users.noreply.github.com>
Signed-off-by: Benjamin Coenen <5719034+bnjjj@users.noreply.github.com>
Signed-off-by: Benjamin Coenen <5719034+bnjjj@users.noreply.github.com>
Signed-off-by: Benjamin Coenen <5719034+bnjjj@users.noreply.github.com>
Signed-off-by: Benjamin Coenen <5719034+bnjjj@users.noreply.github.com>
@netlify
Copy link

netlify bot commented Jun 2, 2022

Deploy Preview for apollo-router-docs failed.

Name Link
🔨 Latest commit f800552
🔍 Latest deploy log https://app.netlify.com/sites/apollo-router-docs/deploys/629884d0838e700008faf590

@github-actions
Copy link
Contributor

github-actions bot commented Jun 2, 2022

@bnjjj your pull request is missing a changelog!

@bnjjj bnjjj changed the title Bnjjj/to defer Split queries for defer directive Jun 2, 2022
@bnjjj
Copy link
Contributor Author

bnjjj commented Jun 2, 2022

Perf test please

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.

Defer: split queries into primary and deferred queries for format_response
1 participant